Closed JSteunou closed 10 years ago
For our own js-based projects, I think we would like jspot to be a single tool for people's gettext needs, so we might actually need this feature eventually. Will need to think about this a bit and talk to others, will leave this ticket open so long.
I also just saw a port of gnu gettext for Windows system. I have to test it to see if a grunt shell task using msgmerge could work with that port. It could be a good alternative.
I've discussed this with @hodgestar, and it seems like merging .pot files into .po files is more a task for the translation tools that read .pot files and output .po files (like poedit or pootle). Maybe we are missing a valid use case though. If you still need this feature, could you explain how you would be using it?
I see. I'm using Grunt a lot and I have a task that generate .pot but also update .po so the translator just need to open catalogs and translate. I'm doing this with grunt-shell triggering msgmerge. Once the .po are up to date, I launch another task that convert .po to .json with po2json.
If you update the .po files then the translator can't see what has changed easily when they edit it? I think the correct workflow is just to update the .pot file and then let the maintainer of the .po file incorporate that using whatever tools they prefer?
He does see. POEdit highlight lines that are new or fuzzy. Never had issues with that. When the translator update its .po with the new .pot it does the same thing that msgmerge does.
The idea behind that is translator could be no professional translator. Some people internal at the firm. So if you can avoid some complicated step to their eye, so they just have to open the file with POEdit and see new lines to process, it is a good win. And I do that in the build process.
Any reason to not just use msgmerge directly then?
Windows. I have to test GNU gettext on windows as wrote above.
Ah, I see. :/
Good news, GNU Gettext can be install and use on Windows with msgmerge & msginit working well. I was able to make a grunt task for the process.
Yay! :) Closing this ticket then, if that is alright. Happy to re-open it if needed later on.
The second missing GNU gettext tool in JS is msgmerge to update po files in a full JS dev env. (Like with Grunt / Gulp)
I work with people on Windows (sadly) and they do not have access to the msgmerge command.
It is now possible to create pot file, with jspot or jsgettext or grunt-xgettext or ... but it is not possible to create or update po file without GNU gettext tools.
How about extending jspot to update po files or create a new project for this?
I know it is a big request but I could totally work with you.