]> git.ipfire.org Git - ipfire-3.x.git/commitdiff
make-batch: Don't send a mail when build was successful.
authorMichael Tremer <michael.tremer@ipfire.org>
Thu, 21 May 2009 12:55:22 +0000 (14:55 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Thu, 21 May 2009 12:55:22 +0000 (14:55 +0200)
After this change the builders will only send a mail when
an error occured.

tools/make-batch

index 4187eb08f5777e8c8db392df48d3ad468c848c2e..09b60807b6122d6edee644070875a5696ad7094d 100644 (file)
@@ -50,19 +50,17 @@ batch_run() {
        $0 build &> $BATCHLOG
        sleep 30
        if [ -e "$FAILED" ]; then
-               SUBJECT="Failed :("
+               batch_mail "Build failed :("
        else
-               SUBJECT="Success!"
                puttarget
        fi
-       SUBJECT=$SUBJECT batch_mail
 }
 
 ###############################################################################                   
 # A function to send an email to the developers                               #
 ###############################################################################
 batch_mail() {
-       MAIL_SUBJECT="[build.ipfire.org - ${HOSTNAME}] - ${SUBJECT}"
+       MAIL_SUBJECT="[${HOSTNAME}] - ${1}"
 
        for i in MAIL_SERVER MAIL_TO MAIL_FROM MAIL_USER MAIL_PASS MAIL_SUBJECT; do
                [ -n "${!i}" ] && export ${i}="${!i}"