godot-third-person-basic-scene/locales/locale.sh

28 lines
531 B
Bash
Raw Normal View History

2022-02-24 22:08:03 +00:00
#!/bin/bash
2022-02-12 19:45:44 +00:00
WORKDIR="$(dirname $(readlink -f $0))"
function generate_locale()
{
echo "--- Begin : $1"
if [ -f $1.po ]
then
msgmerge --update --backup=none $1.po messages.pot
else
msginit --no-translator --input=messages.pot --locale=$1
fi
echo "--- Check : $1"
msgfmt $1.po --check
echo "--- End : $1"
}
ORIGIN=$PWD
cd $WORKDIR
#######################
# LIST LANGUAGE : START
#######################
generate_locale fr
generate_locale en
######################
# LIST LANGUAGE : END
######################
cd $ORIGIN