Localization workflow for updating a development language

I have a project in which I set localization using NSLocalizedString with keys instead of the actual values ​​for the text parameters, i.e. something like this:

NSLocalizedString("RunningDistance", "distance for a marathon")

instead of this:

NSLocalizedString("Running distance.", "distance for a marathon")

Then I exported them to xliff for translation and import back; and it all works. Now I want to add new lines (and many of them).

I read that it is currently not recommended (and supported) to use genstrings for fast. I thought I should export the development language to xliff, add translations and reimport. I tried this and I got the error. The XLIFF file does not contain a target language .

  • Does this mean that I need to add all these lines manually in Localizable.strings and elsewhere (since I use basic localizations)?

  • Is there any other way to do this and import the xliff base language?

+5
source share

Source: https://habr.com/ru/post/1259193/


All Articles