Translation Tools

davidpersson edited this page May 26, 2012 · 2 revisions

Creating a new PO message file from the template.

msginit -l <locale> -i message_default.pot -o <locale>/LC_MESSAGES/default.po \
   --no-translator

Using xgettext tool for extracting message strings as an alternative to li3 g11n extract.

cd <your app directory>
xgettext $(find . -name "*.php") -o resources/g11n/message_default.pot \
   --from-code=utf-8 \
   --keyword=\$t \
   --keyword=\$tn:1,2 \
   --package-name="lithium" \
   --copyright-holder="Union of RAD" \
   --package-version="0.9.9" \
   --msgid-bugs-address="development@example.org"