diff --git a/compile-messages-i2hq.sh b/compile-messages-i2hq.sh index ff20d7ac8cc3ccfcfd4a47687b54dcf240687347..3b723aed50562e3d44d19fb23a9f675171960768 100755 --- a/compile-messages-i2hq.sh +++ b/compile-messages-i2hq.sh @@ -11,3 +11,4 @@ else pybabel compile -D $domain -d $TRANSDIR done fi +touch ./.pybabel-stamp diff --git a/site-updater-i2hq.sh b/site-updater-i2hq.sh index 20652820e7aa403cd1e999b162c3821b86d388de..cb15b52d2282b44b90995c9d3dc24ffff598b931 100755 --- a/site-updater-i2hq.sh +++ b/site-updater-i2hq.sh @@ -1,5 +1,9 @@ #!/bin/sh +cd $(dirname $0) . ./etc/update.vars +[ -f ./etc/update.vars.custom ] && . ./etc/update.vars.custom + +[ ! -f $TOUCHFILE ] && touch $TOUCHFILE TMP=$(mktemp XXXXXXXXXX) trap 'rm -f $TMP;exit' 0 1 2 15 @@ -13,7 +17,11 @@ if grep "^mtn: \(add\|patch\|dropp\|updat\)\(ed\|ing\) 'i2p2www/translations/" " ./compile-messages-i2hq.sh fi +echo "Monotone revision: $(mtn log --no-files --no-graph --to h: | grep Revision | sed 's/Revision: //')" >./i2p2www/pages/include/mtnversion + if grep "^mtn: updating 'i2p2www/.*\.py\|^mtn: updating 'i2p2www/.*/.*\.py" "$TMP" >/dev/null ; then echo "Python files changed, restarting server" touch $TOUCHFILE fi + +[ -f ./.pybabel-stamp ] || ./compile-messages.sh