4 ROOT=$(git rev-parse --show-toplevel)
5 DST=`mktemp -d`/wl-lokalizacja
7 MANAGE=$ROOT/wolnelektury/manage.py
12 for langdir in $ROOT/wolnelektury/locale/*; do
13 lang=`basename $langdir`
15 cp -v ${ROOT}/wolnelektury/locale/${lang}/LC_MESSAGES/django.po $DST/${lang}/wolnelektury.po
18 for appdir in $ROOT/apps/*; do
19 app=`basename $appdir`
20 if [ -d $ROOT/apps/$app/locale ]; then
21 for langdir in $ROOT/apps/$app/locale/*; do
22 lang=`basename $langdir`
24 cp -v ${ROOT}/apps/${app}/locale/${lang}/LC_MESSAGES/django.po $DST/${lang}/${app}.po
29 cp -v ${ROOT}/wolnelektury/static/js/locale.js $DST/locale.js.txt
30 cp -v ${ROOT}/apps/infopages/fixtures/infopages.json $DST/infopages.json
32 ${0}-json.py $DST/infopages.json
37 echo "Generate po for WL"
38 $MANAGE makemessages --all
42 echo "Generate po for app $i"
43 ( cd $i; $MANAGE makemessages --all;
49 PACK=`pwd`/wl-lokalizacja.zip
50 ( cd $DST; cd ..; zip -r $PACK wl-lokalizacja; )