diff --git a/compile-messages.sh b/compile-messages.sh index 42bf632655842f955a9f713c04e8abf1cfb02394..18b88163e8c6c216c79652d0fa05dd16e4fb65ee 100755 --- a/compile-messages.sh +++ b/compile-messages.sh @@ -1,6 +1,11 @@ #!/bin/sh . ./translation.vars -for domain in $(ls $BABELCFG); do - TZ=UTC env/bin/pybabel compile -D $domain -d $TRANSDIR -done +if [ $# -ge 1 ] +then + TZ=UTC env/bin/pybabel compile -D $1 -d $TRANSDIR +else + for domain in $(ls $BABELCFG); do + TZ=UTC env/bin/pybabel compile -D $domain -d $TRANSDIR + done +fi diff --git a/extract-messages.sh b/extract-messages.sh index 62e3dc81e28ebff622d95995fd4e80371b3345c2..bfedfc2755c3b590abb7b87305db2106578d8c90 100755 --- a/extract-messages.sh +++ b/extract-messages.sh @@ -5,10 +5,19 @@ if [ ! -e $POTDIR ]; then mkdir $POTDIR fi -for domain in $(ls $BABELCFG); do +if [ $# -ge 1 ] +then TZ=UTC ./pybabel extract --msgid-bugs-address="http://trac.i2p2.de" \ + --project=$PROJECT \ + --version=$VERSION \ + -F $BABELCFG/$1 \ + -o $POTDIR/$1.pot $PROJDIR +else + for domain in $(ls $BABELCFG); do + TZ=UTC ./pybabel extract --msgid-bugs-address="http://trac.i2p2.de" \ --project=$PROJECT \ --version=$VERSION \ -F $BABELCFG/$domain \ -o $POTDIR/$domain.pot $PROJDIR -done + done +fi diff --git a/update-existing-po.sh b/update-existing-po.sh index fc43574a7bc7fe76b40f15e26a4e9fb0ccc6304e..52888732af37d2659851b13d4e3320e0f6243dc2 100755 --- a/update-existing-po.sh +++ b/update-existing-po.sh @@ -1,6 +1,11 @@ #!/bin/sh . ./translation.vars -for domain in $(ls $BABELCFG); do - TZ=UTC env/bin/pybabel update -D $domain -i $POTDIR/$domain.pot -d $TRANSDIR -done +if [ $# -ge 1 ] +then + TZ=UTC env/bin/pybabel update -D $1 -i $POTDIR/$1.pot -d $TRANSDIR +else + for domain in $(ls $BABELCFG); do + TZ=UTC env/bin/pybabel update -D $domain -i $POTDIR/$domain.pot -d $TRANSDIR + done +fi