Created
June 8, 2018 17:02
-
-
Save tairov/cc575aa7a9192f24e471fddb1d602978 to your computer and use it in GitHub Desktop.
shared library jenkins
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
# shared library | |
// mylib/vars/myGitlabStage.groovy | |
call (String _stage, Closure _closure, String _label = 'master') { | |
stage(_stage) { | |
node (_label) { | |
gitlabCommitStatus(name: _stage ) { | |
_closure() | |
} | |
} // node | |
} //stage | |
# pipeline | |
myGitlabStage('super-stage') { | |
// load gitlab repository | |
echo "Hello World!" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment