branch-api-plugin
branch-api-plugin copied to clipboard
[JENKINS-47874] Support multiple repositories in multi-branch pipeline
As described in the issue JENKINS-47874 I would like to be able to configure multiple repositories with same branch names in a single multi branch project.
To allow this setup, a new BranchProperty
is added which allows the configuration of a pattern that is used to optionnaly customize the branch name in jenkins.branch.Branch#getName()
.
- [x] Make sure you are opening from a topic/feature/bugfix branch (right side) and not your main branch!
- [x] Ensure that the pull request title represents the desired changelog entry
- [x] Please describe what you did
- [x] Link to relevant issues in GitHub or Jira
- [ ] Link to relevant pull requests, esp. upstream and downstream changes
- [x] Ensure you have provided tests - that demonstrates feature works or fixes the issue
Could add a help file that explains this is intended for disambiguating when there are multiple branch sources with possibly overlapping branch names.
Are you still working on this feature or has there been any feedback from the project through other channels? I've run into this issue as well, and this feature would be very useful.
Hello, I'm updating the fork from time to time, but ended up going in a different direction. I've never had any feedback, so maybe I'm missing something (It's my first try of submitting a PR)
From a five-second glance, the code is probably OK, but the motivation remains unclear and I would suggest the PR and the Jira issue be closed as “will not do”. Whatever the ultimate goal may be, there is probably a more straightforward way to accomplish it.