Report a skipped nightly build in a status file instead of by echoing text, such...
authorbvassche <bvassche@d57e44dd-8a1f-0410-8b47-8ef2f437770f>
Tue, 28 Apr 2009 11:04:07 +0000 (11:04 +0000)
committerbvassche <bvassche@d57e44dd-8a1f-0410-8b47-8ef2f437770f>
Tue, 28 Apr 2009 11:04:07 +0000 (11:04 +0000)
git-svn-id: https://scst.svn.sourceforge.net/svnroot/scst/trunk@809 d57e44dd-8a1f-0410-8b47-8ef2f437770f

nightly/bin/nightly

index a504acb..b20ce28 100755 (executable)
@@ -70,6 +70,10 @@ svn_new_date=`date --date=today     +%Y-%m-%dT%H:%M:%S`
 
 cd $ABT_TOP
 
 
 cd $ABT_TOP
 
+# Clean up output files produced by a previous run.
+rm -rf diffs diff.short final new.short new.verbose old.short old.verbose
+rm -rf sendmail.log unchanged.log
+
 # Setup any relevant environment variables from conf/<tag>.conf.
 . conf/$ABT_MACHINE.conf
 if [ "${ABT_JOBS}" = "" ]; then
 # Setup any relevant environment variables from conf/<tag>.conf.
 . conf/$ABT_MACHINE.conf
 if [ "${ABT_JOBS}" = "" ]; then
@@ -90,7 +94,8 @@ fi
 svn_old_rev="`get_svn_revision ${svn_old_date}`"
 svn_new_rev="`get_svn_revision ${svn_new_date}`"
 if [ "${svn_old_rev}" = "${svn_new_rev}" ]; then
 svn_old_rev="`get_svn_revision ${svn_old_date}`"
 svn_new_rev="`get_svn_revision ${svn_new_date}`"
 if [ "${svn_old_rev}" = "${svn_new_rev}" ]; then
-  echo "No changes have been committed between ${svn_old_date} (r${svn_old_rev}) and ${svn_new_date} (r${svn_new_rev})."
+  echo "Both {$svn_old_date} and {$svn_new_date} correspond to r${svn_new_rev}"\
+       "-- skipping nightly build." >unchanged.log
   exit 0
 fi
 
   exit 0
 fi