root/trunk/gregarius/dist/l10n.sh

Revision 1688, 0.6 kB (checked in by mbonetti, 22 months ago)

updated l10n script

Line 
1#!/bin/zsh
2if [ !  -f dist/l10n.sh ]; then
3        echo "Run this script from within the gregarius directory!" >&2
4  exit 1
5fi
6
7POS=`find intl -name LC_MESSAGES -type d`
8POT=intl/messages.pot
9touch $POT
10echo "Updating template: $POT"
11find . -name \*.php | xargs xgettext -o $POT --no-wrap -j -lPHP -k__
12
13POFILE=messages.po
14MOFILE=messages.mo
15POXFILE=messages.pox
16
17for PO in $POS; do
18        echo "Updating $PO/$POFILE"
19        touch $PO/$POFILE
20        msgmerge  -v -F --no-wrap --update --no-fuzzy-matching  $PO/$POFILE $POT
21        echo "Building $PO/$MOFILE"     
22        msgfmt -o $PO/$MOFILE $PO/$POFILE
23        echo
24done
Note: See TracBrowser for help on using the browser.