summaryrefslogtreecommitdiff
path: root/util/updatepo.sh
diff options
context:
space:
mode:
authorShadowNinja <shadowninja@minetest.net>2015-01-21 14:12:14 -0500
committerkwolekr <kwolekr@minetest.net>2015-02-05 03:23:53 -0500
commitefeb372e95e3bd056c0821c203fabc4e5d685c1f (patch)
tree1df3d37acb37c57d986aa4a681d15a190cf51d54 /util/updatepo.sh
parentbec5d3ab227c1535797c286ad0b02d8190fd19fd (diff)
downloadminetest-efeb372e95e3bd056c0821c203fabc4e5d685c1f.tar.gz
minetest-efeb372e95e3bd056c0821c203fabc4e5d685c1f.tar.bz2
minetest-efeb372e95e3bd056c0821c203fabc4e5d685c1f.zip
Add wstrgettext to list of translation update keywords
Diffstat (limited to 'util/updatepo.sh')
-rwxr-xr-xutil/updatepo.sh17
1 files changed, 11 insertions, 6 deletions
diff --git a/util/updatepo.sh b/util/updatepo.sh
index 29d1f2fb1..e9c113224 100755
--- a/util/updatepo.sh
+++ b/util/updatepo.sh
@@ -49,10 +49,15 @@ cd ..
# --package-name
potfile=po/minetest.pot
xgettext --package-name=minetest \
- -kN_ -kwgettext -kfgettext \
- -F -n -o $potfile \
- `find src/ -name '*.cpp' -o -name '*.h'` \
- `find builtin/ -name '*.lua'`
+ --sort-by-file \
+ --add-location \
+ --keyword=N_ \
+ --keyword=wgettext \
+ --keyword=fgettext \
+ --keyword=wstrgettext \
+ --output $potfile \
+ `find src/ -name '*.cpp' -o -name '*.h'` \
+ `find builtin/ -name '*.lua'`
# Now iterate on all languages and create the po file if missing, or update it
# if it exists already
@@ -60,10 +65,10 @@ for lang in $langs ; do # note the missing quotes around $langs
pofile=po/$lang/minetest.po
if test -e $pofile; then
echo "[$lang]: updating strings"
- msgmerge -F -U $pofile $potfile
+ msgmerge --update --sort-by-file $pofile $potfile
else
# This will ask for the translator identity
echo "[$lang]: NEW strings"
- msginit -l $lang -o $pofile -i $potfile
+ msginit --locale=$lang --output-file=$pofile --input=$potfile
fi
done