diff options
Diffstat (limited to 'utils')
-rwxr-xr-x | utils/rebase-translations.sh | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/utils/rebase-translations.sh b/utils/rebase-translations.sh index 564267ab8..2bc42c7eb 100755 --- a/utils/rebase-translations.sh +++ b/utils/rebase-translations.sh @@ -10,7 +10,8 @@ xgettext --from-code utf-8 -k__ -kNotify.info -kNotify.error -kNotify.progress \ xgettext --from-code utf-8 -k__ -kNotify.info -kNotify.error -kNotify.progress \ -kngettext:1,2 -L JavaScript -j -o $TEMPLATE `find js plugins -iname '*.js'` -exit +# leave weblate to deal with .po/.mo files +exit 0 update_lang() { if [ -f $1.po ]; then @@ -21,10 +22,14 @@ update_lang() { fi } +compile_po() { + msgfmt --statistics $1.po -o $1.mo +} + LANGS=`find locale -name 'messages.po'` for lang in $LANGS; do echo Updating $lang... PO_BASENAME=`echo $lang | sed s/.po//` - update_lang $PO_BASENAME + compile_po $PO_BASENAME done |