aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatt Rendina <mrendina@stsci.edu>2017-11-21 14:55:32 -0500
committerMatt Rendina <mrendina@stsci.edu>2017-11-21 14:55:32 -0500
commit66734368bdf45af0cb910c7934443d773f34eb20 (patch)
tree2ddff8a0444e7a4880a36e43374f530f1a5af4bc
parent728e11549ceed0129db43c008b625f57aecf558b (diff)
downloadjscu_refactor-66734368bdf45af0cb910c7934443d773f34eb20.tar.gz
Test System.exit
-rw-r--r--vars/jfile_utils.groovy16
1 files changed, 8 insertions, 8 deletions
diff --git a/vars/jfile_utils.groovy b/vars/jfile_utils.groovy
index 9de646c..d190739 100644
--- a/vars/jfile_utils.groovy
+++ b/vars/jfile_utils.groovy
@@ -1,5 +1,10 @@
// Jenkinsfile utilities
+// Clone the source repository and examine the most recent commit message.
+// If a '[ci skip]' or '[skip ci]' directive is present, immediately abort the build
+// terminate the job with a success code.
+// If no skip directive is found, stash all the source files for efficient retrieval
+// by subsequent nodes.
def scm_checkout() {
skip_job = 0
node("on-master") {
@@ -11,20 +16,15 @@ def scm_checkout() {
skip_job = 1
currentBuild.result = 'SUCCESS'
println("\nBuild skipped due to commit message directive.\n")
- return skip_job
+ System.exit(0)
+ //return skip_job
}
stash includes: '**/*', name: 'source_tree'
}
}
- return skip_job
+ //return skip_job
}
-//if (skip_job == 1) {
-// currentBuild.result = 'SUCCESS'
-// println("\nBuild skipped due to commit message directive.\n")
-// return
-//}
-
def concurrent2(mylist) {
for (build in mylist) {