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 d001380  SLING-7245 - Validate pull requests using Jenkins
d001380 is described below

commit d00138033dd77a8a5b23c997c2c4e7320e6362a0
Author: Robert Munteanu <[email protected]>
AuthorDate: Thu Dec 20 16:46:05 2018 +0100

    SLING-7245 - Validate pull requests using Jenkins
    
    BUILD_LOG is a token, not a groovy variable.
---
 vars/slingOsgiBundleBuild.groovy | 13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)

diff --git a/vars/slingOsgiBundleBuild.groovy b/vars/slingOsgiBundleBuild.groovy
index 1aa7803..f464a4a 100644
--- a/vars/slingOsgiBundleBuild.groovy
+++ b/vars/slingOsgiBundleBuild.groovy
@@ -141,11 +141,16 @@ 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.
 
-    emailExt subject: subject, body: """Please see ${currentBuild.absoluteUrl} 
for details.
+        No further emails will be send until the status of the build is 
changed.
 
-No further emails will be sent until the status of the build is changed.
-Build log:
+        Build log:
 
-${BUILD_LOG}""", replyTo: '[email protected]', recipientProviders: 
recipientProviders, to: recipients.join(',')
+    """
+    
+    body += '${BUILD_LOG}'
+
+    emailExt subject: subject, body: body, replyTo: '[email protected]', 
recipientProviders: recipientProviders, to: recipients.join(',')
 }
\ No newline at end of file

Reply via email to