Created
December 2, 2016 13:40
-
-
Save rtyler/14ba266906fc628a21b61fbe916fbd37 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env groovy | |
node { | |
stage('Build') { | |
sh 'make' | |
} | |
stage('Test') { | |
sh 'make check' /* if this returns non-zero, the Pipeline stops */ | |
junit 'reports/**/*.xml' | |
/* otherwise...we could: */ | |
if (currentBuild.result == 'UNSTABLE') { | |
return | |
} | |
} | |
stage('Deploy') { | |
/* .. snip .. */ | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Actually I found that lines 11 to 13 should be moved outside the stage to work propertly