iOS strings files are downloaded with charset UTF-16be (binary)
vpusher opened this issue · comments
When doing a simple phraseapp pull, the .strings
files are downloaded with charset UTF-16be, which makes the files seen as binary files by the system.
They should be text files as XCode generates them with proper charset.
This is a blocker for me since I do some text manipulation on the .strings
files using bash commands after pulling them.
Even worse, it is breaking the encoding at runtime....
It happens on both MacOS and Linux.
Built at: 2018-04-05T09:54:59Z
PhraseApp Client version: 1.6.1
PhraseApp Client revision: a31515b4d10d1c91d9479bd103519b1e3ff8ef08
PhraseApp Library revision: ed442d8d052dac9d06d4c2f0c3b25970d046a022
PhraseApp Docs revision client:
PhraseApp Docs revision lib:
PhraseApp Generator revision client:
PhraseApp Generator revision lib:
GoVersion: go1.8.7
When downloading a locale it is possible to choose the encoding. For example you could use UTF-8 in this case. The config could look like this:
phraseapp:
project_id: <PROJECT_ID>
push:
sources:
- file: ./<locale_code>.lproj/Localizable.strings
params:
file_format: strings
pull:
targets:
- file: ./<locale_code>.lproj/Localizable.strings
params:
file_format: strings
encoding: UTF-8
Let me know if you have any further questions
Great. It is working. Thanks a lot! Where can I find documentation about all the possible values for the params
field?
Glad to hear that it helped. The Client uses the same params as the API. For example here we have a list of all available params for download endpoint: https://phraseapp.com/docs/api/v2/locales/#download