concrete5/concrete5 — pull request #1591 by mlocati (2014-02-07 17:45:54+00:00)
Title: Add grunt task to localize packages

In order to localize a package, developers need to create the gettext template file (.pot), and a gettext .po file for each language.
Let's implement a grunt task that do it: `grunt localize`!
It accepts the following parameters:
- `--package`: the handle of the package to be translated
- `--locales`: the list of locales to be generated

The locales parameter can also be set to simply `-` (minus sign) to tell to the task that we don't want to generate/update the .po files.
If the `locales` parameter is omitted, the grunt task will update the existing locales that it find.
Furthermore, if a locale has a .mo file but not a .po file, the task is smart enough to decompile the .mo file to the .po format.

Final note: the translations in existing .po files won't be overwritten, but just updated by adding the new translations found.