mirror of
https://github.com/minetest/minetest.git
synced 2024-11-27 01:53:45 +01:00
Add wstrgettext to list of translation update keywords
This commit is contained in:
parent
bec5d3ab22
commit
efeb372e95
@ -49,10 +49,15 @@ cd ..
|
|||||||
# --package-name
|
# --package-name
|
||||||
potfile=po/minetest.pot
|
potfile=po/minetest.pot
|
||||||
xgettext --package-name=minetest \
|
xgettext --package-name=minetest \
|
||||||
-kN_ -kwgettext -kfgettext \
|
--sort-by-file \
|
||||||
-F -n -o $potfile \
|
--add-location \
|
||||||
`find src/ -name '*.cpp' -o -name '*.h'` \
|
--keyword=N_ \
|
||||||
`find builtin/ -name '*.lua'`
|
--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
|
# Now iterate on all languages and create the po file if missing, or update it
|
||||||
# if it exists already
|
# if it exists already
|
||||||
@ -60,10 +65,10 @@ for lang in $langs ; do # note the missing quotes around $langs
|
|||||||
pofile=po/$lang/minetest.po
|
pofile=po/$lang/minetest.po
|
||||||
if test -e $pofile; then
|
if test -e $pofile; then
|
||||||
echo "[$lang]: updating strings"
|
echo "[$lang]: updating strings"
|
||||||
msgmerge -F -U $pofile $potfile
|
msgmerge --update --sort-by-file $pofile $potfile
|
||||||
else
|
else
|
||||||
# This will ask for the translator identity
|
# This will ask for the translator identity
|
||||||
echo "[$lang]: NEW strings"
|
echo "[$lang]: NEW strings"
|
||||||
msginit -l $lang -o $pofile -i $potfile
|
msginit --locale=$lang --output-file=$pofile --input=$potfile
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
Loading…
Reference in New Issue
Block a user