From: Joerg Jaspert Date: Mon, 13 Dec 2010 22:49:05 +0000 (+0100) Subject: cron.buildd X-Git-Url: https://git.decadent.org.uk/gitweb/?a=commitdiff_plain;h=957941c8d4a13dc381dbdf9558ec75824c9ea9e9;p=dak.git cron.buildd whitespace fun Signed-off-by: Joerg Jaspert --- diff --git a/config/debian-security/cron.buildd b/config/debian-security/cron.buildd index e52cbb4a..7bd0e7e6 100755 --- a/config/debian-security/cron.buildd +++ b/config/debian-security/cron.buildd @@ -11,12 +11,12 @@ SSH_SOCKET=~/.ssh/buildd.debian.org.socket DISTS=$(dak admin s list) if [ -e $ftpdir/Archive_Maintenance_In_Progress ]; then - exit 0 + exit 0 fi for dist in $DISTS; do - eval SOURCES_$dist=`stat -c "%Y" $base/buildd/$dist/Sources.gz` - eval PACKAGES_$dist=`stat -c "%Y" $base/buildd/$dist/Packages.gz` + eval SOURCES_$dist=`stat -c "%Y" $base/buildd/$dist/Sources.gz` + eval PACKAGES_$dist=`stat -c "%Y" $base/buildd/$dist/Packages.gz` done cd $configdir @@ -35,39 +35,39 @@ dists= for dist in $DISTS; do - eval NEW_SOURCES_$dist=`stat -c "%Y" $base/buildd/$dist/Sources.gz` - eval NEW_PACKAGES_$dist=`stat -c "%Y" $base/buildd/$dist/Packages.gz` - old=SOURCES_$dist + eval NEW_SOURCES_$dist=`stat -c "%Y" $base/buildd/$dist/Sources.gz` + eval NEW_PACKAGES_$dist=`stat -c "%Y" $base/buildd/$dist/Packages.gz` + old=SOURCES_$dist new=NEW_$old if [ ${!new} -gt ${!old} ]; then - if [ -z "$dists" ]; then - dists="$dist" - else - dists="$dists $dist" - fi - continue - fi - old=PACKAGES_$dist - new=NEW_$old + if [ -z "$dists" ]; then + dists="$dist" + else + dists="$dists $dist" + fi + continue + fi + old=PACKAGES_$dist + new=NEW_$old if [ ${!new} -gt ${!old} ]; then - if [ -z "$dists" ]; then - dists="$dist" - else - dists="$dists $dist" - fi - continue - fi + if [ -z "$dists" ]; then + dists="$dist" + else + dists="$dists $dist" + fi + continue + fi done if [ ! -z "$dists" ]; then - # setup ssh master process - ssh wbadm@buildd -S $SSH_SOCKET -MN 2> /dev/null & - SSH_PID=$! - while [ ! -S $SSH_SOCKET ]; do - sleep 1 - done - trap 'kill -TERM $SSH_PID' 0 - for d in $dists; do - ssh wbadm@buildd -S $SSH_SOCKET trigger.security $d - done + # setup ssh master process + ssh wbadm@buildd -S $SSH_SOCKET -MN 2> /dev/null & + SSH_PID=$! + while [ ! -S $SSH_SOCKET ]; do + sleep 1 + done + trap 'kill -TERM $SSH_PID' 0 + for d in $dists; do + ssh wbadm@buildd -S $SSH_SOCKET trigger.security $d + done fi