This is an automated email from the ASF dual-hosted git repository.

tibordigana pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/maven-surefire.git


The following commit(s) were added to refs/heads/master by this push:
     new b94cb56  [INFRA-18734] Jenkins builds fail on email notifications due 
to unknown user ID "github"
b94cb56 is described below

commit b94cb56ada20a644a36a17ca1cc5a7a7854efd09
Author: tibordigana <[email protected]>
AuthorDate: Fri Aug 2 16:28:47 2019 +0200

    [INFRA-18734] Jenkins builds fail on email notifications due to unknown 
user ID "github"
---
 Jenkinsfile | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/Jenkinsfile b/Jenkinsfile
index 4b906d6..fb34641 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -112,7 +112,10 @@ timeout(time: 12, unit: 'HOURS') {
         currentBuild.result = 'FAILURE'
         throw e
     } finally {
-        jenkinsNotify()
+        def isFirstBuild = currentBuild == null || currentBuild.changeSets == 
null
+        def authors = isFirstBuild ? [] : 
currentBuild.changeSets.last().toList().collect { it.author.toString() 
}.unique()
+        println("The author of the last change: ${authors}")
+        if (isFirstBuild || !authors.contains('github')) jenkinsNotify()
     }
 }
 

Reply via email to