This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to branch feature/SLING-7245
in repository https://gitbox.apache.org/repos/asf/sling-tooling-jenkins.git
The following commit(s) were added to refs/heads/feature/SLING-7245 by this
push:
new 9194d03 SLING-7245 - Validate pull requests using Jenkins
9194d03 is described below
commit 9194d0309706843989f4cb8d3c5d1ec6d14b3b15
Author: Robert Munteanu <[email protected]>
AuthorDate: Thu Dec 20 16:46:05 2018 +0100
SLING-7245 - Validate pull requests using Jenkins
Only include the build log if the build is broken
---
vars/slingOsgiBundleBuild.groovy | 14 ++++++--------
1 file changed, 6 insertions(+), 8 deletions(-)
diff --git a/vars/slingOsgiBundleBuild.groovy b/vars/slingOsgiBundleBuild.groovy
index 8df3766..294230d 100644
--- a/vars/slingOsgiBundleBuild.groovy
+++ b/vars/slingOsgiBundleBuild.groovy
@@ -141,17 +141,15 @@ def processResult(def currentBuild, String previous, def
recipients) {
echo "Status change is ${change}, notifications will be sent."
def subject = "[Jenkins] ${currentBuild.fullDisplayName} is ${change}"
- def body = """
- Please see ${currentBuild.absoluteUrl} for details.
-
- No further emails will be send until the status of the build is
changed.
-
- Build log:
+ def body = """Please see ${currentBuild.absoluteUrl} for details.
+No further emails will be sent until the status of the build is changed.
"""
-
- body += '${BUILD_LOG}'
+ if ( change == "BROKEN") {
+ body += "Build log follows below:\n\n"
+ body += '${BUILD_LOG}'
+ }
def recipientList = []
recipients.each { r -> recipientList.add(r) }