-
Bug
-
Resolution: Fixed
-
Critical
-
None
I set the refscpec such that Jenkins would not include the repo name in the branch name. Jenkins still appended the repo name to the branch name. I need the branch names in Jenkins to match that of the origin so that gitVersion functions correctly. See the attached image for details
- is related to
-
JENKINS-33984 Git plugin sets wrong branch name GIT_BRANCH (more than 2 branches with same SHA1)
-
- Open
-
Could explain in more detail (or with examples) what you mean when you say that "Jenkins would not include the repo name in the branch name"?
Is your goal to checkout a local branch named like the remote branch, as in "master" is checked out if the remote branch is "origin/master"? If so, then you can get that with git plugin 2.4.4 and later using the "Checkout to local branch" additional behaviour. Use the value "**", or leave the field blank. The plugin will then infer the branch name from the remote branch name.