How i can add phing task for automated parsing my project and cresting a PO for translation?

StackOverflow https://stackoverflow.com//questions/12669447

Вопрос

How i can add phing task for automated parsing my project and creating a PO for translation?

Это было полезно?

Решение

You can use xgettext to collect all gettext-translatable strings:

http://sourceforge.net/p/semanticscuttle/code/ci/cb4b0469ca48d9865c8b162c1446d9011adf249b/tree/scripts/update-translation-base.php#l11

$ xgettext -kT_ngettext:1,2 -kT_ -L PHP  -o data/locales/messages.po src/

Execute that from your phing task.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top