From 8c8a02874f485385547e6c4267073281b3d24552 Mon Sep 17 00:00:00 2001 From: str4d <str4d@mail.i2p> Date: Sat, 9 Nov 2013 20:10:57 +0000 Subject: [PATCH] Updated i2hq scripts to match regular ones --- compile-messages-i2hq.sh | 6 ++++-- site-updater-i2hq.sh | 7 ++++--- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/compile-messages-i2hq.sh b/compile-messages-i2hq.sh index a087a40a6..ff20d7ac8 100755 --- a/compile-messages-i2hq.sh +++ b/compile-messages-i2hq.sh @@ -1,11 +1,13 @@ #!/bin/sh . ./etc/translation.vars +export TZ=UTC + if [ $# -ge 1 ] then - TZ=UTC pybabel compile -D $1 -d $TRANSDIR + pybabel compile -D $1 -d $TRANSDIR else for domain in $(ls $BABELCFG); do - TZ=UTC pybabel compile -D $domain -d $TRANSDIR + pybabel compile -D $domain -d $TRANSDIR done fi diff --git a/site-updater-i2hq.sh b/site-updater-i2hq.sh index 603d2b352..a3fe64227 100755 --- a/site-updater-i2hq.sh +++ b/site-updater-i2hq.sh @@ -3,14 +3,15 @@ TMP=$(mktemp XXXXXXXXXX) trap 'rm -f $TMP;exit' 0 1 2 15 mtn pull -mtn update 2>&1 | tee $TMP +mtn up 2>&1 | tee $TMP -if grep "^mtn: \(add\|dropp\|updat\)ing 'i2p2www/translations/" "$TMP" >/dev/null; then + +if grep "^mtn: \(add\|patch\|dropp\|updat\)\(ed\|ing\) 'i2p2www/translations/" "$TMP" >/dev/null ; then echo "Translations updated, compiling messages" ./compile-messages-i2hq.sh fi -if grep "^mtn: updating 'i2p2www/.*\.py\|^mtn: updating 'i2p2www/.*/.*\.py" "$TMP" >/dev/null; then +if grep "^mtn: updating 'i2p2www/.*\.py\|^mtn: updating 'i2p2www/.*/.*\.py" "$TMP" >/dev/null ; then echo "Python files changed, restarting server" touch /tmp/2fcd2f17-c293-4f77-b4c9-9b266ba70daa fi -- GitLab