Reputation: 175
I am creating a freestyle job with the Jenkins Job DSL. It appears to create a git tag every time. The default for scm -> git -> createTag appears to be "false", but this is deprecated. Was this turned ON elsewhere?
My code snippet is as follows (I added the createTag line to try to fix it, but it creates the add tag in "additional behaviors" anyway). Suggestions on how to fix?
scm {
git(buildRepoName, branchName) {
createTag(false)
}
}
Upvotes: 2
Views: 972
Reputation: 8194
If you use the git
method with a closure parameter, the "create tag" option is disabled by default. See the API Viewer for details. See also JENKINS-33482.
job('example') {
scm {
git {
remote {
url('https://github.com/jenkinsci/job-dsl-plugin.git')
}
branch('master')
}
}
}
Upvotes: 2