diff --git a/translations/generate_po.sh b/translations/generate_po.sh index 549e8da..7f3e73c 100644 --- a/translations/generate_po.sh +++ b/translations/generate_po.sh @@ -33,6 +33,9 @@ fi echo "Running po generation with arguments:" echo "sources_path: \"${sources_path}\" locales_path: \"${locales_path}\" lang_code: \"${lang_code}\"" +# Ensure the po file exists and is writable +touch ${locales_path}/${lang_code}.po + # Generate new empty po file cd ${sources_path} find . -iname "*.js" | \ @@ -52,6 +55,7 @@ cd - >/dev/null # Merge old and new po files sed --in-place --expression=s/CHARSET/UTF-8/ ${sources_path}/tmp.po + msgmerge \ --no-wrap \ --lang=${lang_code} \