diff options
author | Holger Levsen <holger@layer-acht.org> | 2017-01-21 12:14:40 +0100 |
---|---|---|
committer | Holger Levsen <holger@layer-acht.org> | 2017-01-21 12:14:40 +0100 |
commit | 27bd26bb9781bba483726849b8ef808ea6d8f974 (patch) | |
tree | d4b8f4744cc2ade76ae1f379c22064f9907ceca8 /bin/reproducible_maintenance.sh | |
parent | 9be2b23d7960a4cc9317e36fbc00f90f92c53e5c (diff) | |
download | jenkins.debian.net-27bd26bb9781bba483726849b8ef808ea6d8f974.tar.xz |
reproducible Debian: only send mail about problems if problems were found
Signed-off-by: Holger Levsen <holger@layer-acht.org>
Diffstat (limited to 'bin/reproducible_maintenance.sh')
-rwxr-xr-x | bin/reproducible_maintenance.sh | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/bin/reproducible_maintenance.sh b/bin/reproducible_maintenance.sh index d747fa59..64427dd6 100755 --- a/bin/reproducible_maintenance.sh +++ b/bin/reproducible_maintenance.sh @@ -473,7 +473,8 @@ if [ "$HOSTNAME" = "$MAINNODE" ] && [ $(date -u +%H) -eq 0 ] ; then # only care for yesterday's entries: ( grep $(date -u -d "1 day ago" '+%Y-%m-%d') $PROBLEM || echo "no problems yesterday…" ) > $TMPFILE fi - if [ -s $TMPFILE ] ; then + # send mail if we found issues + if [ -s $TMPFILE ] && ! grep -q "no problems yesterday…" $TMPFILE ; then cat $TMPFILE | mail -s "$(basename $PROBLEM) found" qa-jenkins-scm@lists.alioth.debian.org fi rm -f $TMPFILE |