I have an application in which I used gettext to allow easy translation.
The problem that I have is that everytime I need to release a new version, I have to scan the .php files with the ICanLocalize scanner and this gives me a new .po file.
While it’s ok for the default language, whenever I need to translate it to another one, I have to start all over again from that same new file.
I know I’m missing a big feature of gettext by doing this, but I don’t know which is it or how to use it. I’ve tried googling and the only clue I got is that I need to generate .pot files instead of .po, but I really don’t understand how they work.
My program adds new strings on every release, but also eliminates others, so I wouldn’t like to leave those in the .po files.
I’m a little lost here, could someone give me at least a pointer in the right direction?
Thanks for your help!
EDIT
I found that I can generate the file from within poedit itself, but it brings another problem. I have 3 different text domains on the app and want only one to be on the pot file… I’ll keep looing for solutions
xgettextis used to extract I18N’d strings from source.msgmergemerges an existing .po file into a new .pot file, and results in a new .po file. You’ll have to handle the separate domains yourself, by only passing the appropriate source files.