aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans-Christoph Steiner <eighthave@users.sourceforge.net>2006-08-09 15:03:33 +0000
committerHans-Christoph Steiner <eighthave@users.sourceforge.net>2006-08-09 15:03:33 +0000
commit5c74c569f4e1da55860d945a286d31912130144c (patch)
tree2c4c10b7b4248f04124cc532a22a0b929457a45d
parenteb411f24fa8531f4eb4224835b2a44dc3ffd7261 (diff)
added success test so that it only send the email on failure
svn path=/trunk/; revision=5537
-rwxr-xr-xscripts/auto-build/run-automated-builder9
1 files changed, 6 insertions, 3 deletions
diff --git a/scripts/auto-build/run-automated-builder b/scripts/auto-build/run-automated-builder
index 858c923e..a1962b90 100755
--- a/scripts/auto-build/run-automated-builder
+++ b/scripts/auto-build/run-automated-builder
@@ -15,9 +15,12 @@ run_build_script ()
su pd -c "sh /home/pd/auto-build/${distro}/scripts/auto-build/${distro}-auto-builder.sh" >> $LOGFILE 2>&1
-# send status report
- SUBJECT="$HOSTNAME Pd-$SYSTEM $distro build results $DATE $TIME"
- tail -200 ${LOGFILE} | mail -s "${SUBJECT}" hans@eds.org
+# send status report if something failed
+ completion_test=`tail -1 ${LOGFILE}`
+ if [ "x${completion_test}" != "xSUCCESS" ]; then
+ SUBJECT="$HOSTNAME Pd-$SYSTEM $distro build results $DATE $TIME"
+ tail -200 ${LOGFILE} | mail -s "${SUBJECT}" hans@eds.org
+ fi
}
run_build_script pd-main