[zorg] r318250 - Fix notification for the very first build
Matthias Braun via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 14 17:50:42 PST 2017
Author: matze
Date: Tue Nov 14 17:50:42 2017
New Revision: 318250
URL: http://llvm.org/viewvc/llvm-project?rev=318250&view=rev
Log:
Fix notification for the very first build
Modified:
zorg/trunk/zorg/jenkins/benchmark.groovy
Modified: zorg/trunk/zorg/jenkins/benchmark.groovy
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/zorg/jenkins/benchmark.groovy?rev=318250&r1=318249&r2=318250&view=diff
==============================================================================
--- zorg/trunk/zorg/jenkins/benchmark.groovy (original)
+++ zorg/trunk/zorg/jenkins/benchmark.groovy Tue Nov 14 17:50:42 2017
@@ -37,7 +37,9 @@ private def post_build() {
currentBuild.description += descr_body
// Send notification email.
- if (currentBuild.getPreviousBuild().result != currentBuild.currentResult &&
+ def prev_build = currentBuild.getPreviousBuild()
+ if ((prev_build == null ||
+ prev_build.result != currentBuild.currentResult) &&
currentBuild.currentResult == 'FAILURE') {
def email_template = readTrusted 'zorg/jenkins/email.template'
def body = render_template(email_template, log_summary)
More information about the llvm-commits
mailing list