Translation update done using Pootle.
[wammu.git] / admin / locales-update
blobf349861e33664be6dd84a93ff467dc41ae075814
1 #!/bin/sh
2 # vim: expandtab sw=4 ts=4 sts=4:
3 LOCS=`ls locale/*/wammu.po | sed 's@.*/\(.*\)/[^/]*@\1@'`
4 xgettext \
5 -d wammu \
6 --msgid-bugs-address=michal@cihar.com \
7 -o locale/wammu.pot \
8 --language=Python \
9 --add-comments=l10n \
10 --add-location \
11 --copyright-holder="Michal Čihař" \
12 `find Wammu/ -name '*.py' | sort` wammu-configure.py wammu.py wammu_setup/msgfmt.py
14 ver=`python -c 'import Wammu; print Wammu.__version__'`
16 if [ "x$1" != "x--nopo4a" ] ; then
17 ./admin/po4a
20 for loc in $LOCS ; do
21 cd locale/$loc
22 msgmerge -U -C ../../../gammu/locale/$loc/docs.po -C wammu.po -C ../../../gammu/locale/$loc/gammu.po -C ../../../gammu/locale/$loc/libgammu.po docs.po ../docs.pot
23 cd ../..
24 done
26 sed -i '
27 s/SOME DESCRIPTIVE TITLE/Wammu translation/;
28 s/PACKAGE/Wammu/;
29 s/(C) YEAR/(C) 2003 - '`date +%Y`'/;
30 s/VERSION/'$ver'/;
31 ' locale/wammu.pot
33 for loc in $LOCS ; do
34 sed -i '
35 s/SOME DESCRIPTIVE TITLE/Wammu translation/;
36 s/PACKAGE/Wammu/;
37 s/VERSION/'$ver'/;
38 s/Project-Id-Version: Wammu [0-9.]*/Project-Id-Version: Wammu '$ver'/;
39 ' locale/$loc/wammu.po
40 msgmerge \
41 -C locale/$loc/docs.po \
42 -C ../gammu/locale/$loc/gammu.po \
43 -C ../gammu/locale/$loc/libgammu.po \
44 -C ../gammu/locale/$loc/docs.po \
45 -U locale/$loc/wammu.po locale/wammu.pot
46 done