gCubeBuilder/examples/with_function

24 lines
435 B
Plaintext
Raw Permalink Normal View History

2019-09-02 04:34:58 +02:00
pipeline {
agent any
stages {
stage('build') {
steps {
buildComponents items: ("a".."f").collect { "Stage ${it}" }
}
}
2019-09-02 04:34:58 +02:00
stage('build2') {
steps {
2019-09-02 13:59:42 +02:00
buildComponents items: ("g".."p").collect { "Stage ${it}" }
2019-09-02 04:34:58 +02:00
}
}
}
}
def buildComponents(args) {
parallel args.items.collectEntries { name -> [ "${name}": {
stage("${name}") {
echo name
}
}]}
}