-
New Feature
-
Resolution: Unresolved
-
Minor
I have a maven project stored in Atlassian Stash and have "Branches to build" set blank so that it will respond to any commit in any branch when triggered by stash. This works great for the typical use case but periodically we need to release a version and so we want to use the maven release plugin on the master branch. When we hit "Perform maven release" the job is run using the last modified branch in the git repository rather than the master branch.
Configuring the job to have "Branches to build" set to master allows the maven release plugin to be run but then totally ignores commits to other branches that should be triggering the job.
I've even tried using a BranchToCheckout build parameter defaulting to ** so that it defaults to any branch but maven releases can be run specifically on master (or other release branches) but this ignores other commits too.
Is this a supported feature combination and I just need help getting the config right? Or is this an entirely novel requirement?
I've not seen anyone else mention that use case. There is a change in the 2.4.0 git plugin pre-release which might give you some pointers to consider. Refer to
JENKINS-27327,JENKINS-27351, andJENKINS-27352for more information on the purpose of the change that was included in PR309.