Make some more output

This commit is contained in:
HackerNCoder 2023-02-11 03:22:41 +01:00
parent a1a792316f
commit 9f342d4aa6

View file

@ -17,15 +17,19 @@ for file in ./translations-*.po; do
stats=$(msgfmt --statistics ${file} 2>&1) stats=$(msgfmt --statistics ${file} 2>&1)
numdone=$(echo ${stats%* translated*}) numdone=$(echo ${stats%* translated*})
if [[ $numdone -le 5680 ]]; then if [[ $numdone -le 5680 ]]; then
echo -e "\x1B[36mSKIPPING $file since it has less than 5680 strings translated\x1B[0m"
continue continue
fi fi
if (( $(date -d $(awk '/PO-Revision-Date/{print $2}' ${file}) +%s) < $CI_PREV_BUILD_STARTED )); then if (( $(date -d $(awk '/PO-Revision-Date/{print $2}' ${file}) +%s) < $CI_PREV_BUILD_STARTED )); then
echo -e "\x1B[36mSKIPPING $file since it hasn't been changed since last CI\x1B[0m"
continue continue
fi fi
echo -e "\x1B[36mBUILDING $file \x1B[0m"
msgfmt "$file" -o game.mo msgfmt "$file" -o game.mo
PATH=$(pwd)/renpy:${PATH} RENPY_DIR=$(pwd)/renpy python3 rttk-queerscriptors/mo2tl.py $(pwd)/game-source game.mo ${lang} echo "\t$(PATH=$(pwd)/renpy:${PATH} RENPY_DIR=$(pwd)/renpy python3 rttk-queerscriptors/mo2tl.py $(pwd)/game-source game.mo ${lang})"
zip "${lang}.zip" game-source/game/tl/${lang}/* echo "\t$(zip "${lang}.zip" game-source/game/tl/${lang}/*)"
mv "${lang}.zip" "/var/www/queer/build/${CI_REPO_NAME}/${lang}.zip" mv "${lang}.zip" "/var/www/queer/build/${CI_REPO_NAME}/${lang}.zip"
echo -e "\e[32mFINISHED $file\e[0m"
done done