diff options
Diffstat (limited to 'dist/scripts')
-rwxr-xr-x | dist/scripts/po2mo.sh | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/dist/scripts/po2mo.sh b/dist/scripts/po2mo.sh index 7be049b..79f344d 100755 --- a/dist/scripts/po2mo.sh +++ b/dist/scripts/po2mo.sh @@ -1,9 +1,14 @@ #!/bin/bash -for f in *.po +srcbase=$1 +dstbase=$2 + +echo "Generating locales..." +for f in $(ls $srcbase/*.po) do - mo_dir=${f%%.po}.utf8/LC_MESSAGES/ + fname=$(basename "$f") + mo_dir="$dstbase"/${fname%%.po}.utf8/LC_MESSAGES [ -d "$mo_dir" ] || mkdir -p "$mo_dir" - echo msgfmt -o "$mo_dir/editablesite.mo" "$f" + #echo msgfmt -o "'$mo_dir/editablesite.mo'" "'$f'" msgfmt -o "$mo_dir/editablesite.mo" "$f" done |