Created
January 31, 2017 21:49
-
-
Save antrew/e9760745948d449e0df549878f3bc1f0 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
#!groovy | |
def handleCheckout = { | |
checkout ([ | |
$class: 'GitSCM', | |
branches: scm.branches, | |
extensions: [ | |
[$class: 'PruneStaleBranch'], | |
[$class: 'CleanCheckout'] | |
], | |
userRemoteConfigs: scm.userRemoteConfigs | |
]) | |
} | |
node() { | |
stage('setup') { | |
sh "env | sort" | |
handleCheckout() | |
sh "git branch -vv" | |
} | |
stage('test') { | |
sh "echo 'Throw in some tests here'" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment