Comments (3)
Hey Donald,
I will look into it later this week, I have few things that I want to investigate and this is one of them. My understanding is that xliff files are only for interchange between you as developer and translator, but they should get decoded back to Localizable.strings once you actually import them, right (please correct me if I am wrong)? So that means that at the end (once you do round of export - translate - import), the input can still get processed from .strings and nothing changes internally?
I have not personally worked with them - I will try and see, if it presents some problem that would have to be solved on generator level.
I will keep you posted (and if you can give me more insight, that would be also great).
Have a very nice Xmas
Jiri
from laurine.
Hi Jiri,
Merry Xmas,
Your understanding of the xliff files is entirely correct. The only thing that makes Laurine hard to use with the built-in xliff system is that apple apparently does not allow you to export to xliff existing .strings files, and will only extract translations from storyboards or from NSLocalizedString calls in the code.
Because of this the only way to work with both systems is to keep the Laurine strings in a manually maintained .strings file (not named Localizable.strings, as that will get overwritten during import of xliff files), and then work with two separate translation files when uploading and downloading from translation management platforms, which is really quite cumbersome.
I haven't been able to figure out a good workaround for this problem, as it seems that the only way to get these tools to properly work together would be to modify the tool apple uses to generate the xliff files to include manually generated .strings files (or perhaps get the Laurine generator to create a source file with dummy NSLocalizedString entries just for the purpose of extraction to xliff).
Cheers,
D
from laurine.
Hey,
If you generate code that calls NSLocalizedString* macros directly instead of using the swift String extensions (like you're doing for ObjC) then Xcode will pick up those string when exporting to XLIff.
The Swift extensions do not bring any advantages anyway.
from laurine.
Related Issues (20)
- Compiled Script HOT 1
- Xcode 7.3 support HOT 5
- Support for dictionaries HOT 2
- Detect unused keys
- Deprecated homebrew dependencies HOT 3
- Swift 3 Support? HOT 18
- Can't build Laurine with Swift 2.2 on Mac Sierra HOT 2
- How to use this with many languages? HOT 1
- Laurine's younger Sister - Image Generator [name pending] HOT 2
- Generated Localizations file is incomplete if input file contains certain characters HOT 2
- Swift 4 migration HOT 2
- S3, S4 Support + Laurine Rework (announcement) HOT 9
- Question: What about memory? HOT 1
- Objc localization - String with format specifiers HOT 1
- Laurine fails at -d parameter HOT 1
- (Question) Fallback handling
- "Error.Title.General" is not recognized by Laurine
- "\\(variable)" not work HOT 1
- Feature request: use Base translation as comment
- Xcode 10.2 error HOT 20
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from laurine.