Issue #556 resolved

Branch Write Protect Plugin: Protect only a specific branch

Anonymous created an issue

We need some way to use branch write protect to protect only the master/default branch but allow write access to all other branches. This doesn't seem to be possible at the moment: we apparently need to add all existing and new branches as exceptions to the plugin.

Some way to define negative rules would be great... Judging from the code allowing regular expressions in the branch name (maybe when specified with a regexp: prefix or something) would seem to be the easiest solution, but a more explicit way to specify all-but rules would be great too of course.

Comments (5)

  1. Heinrich Janzing

    Yes :) I just noticed the title isn't very good and sadly I can't seem to correct it since I posted it anonymously... It should of course say "Branch Write Protect Plugin: Protect only a specific branch".

  2. kwaclaw

    I agree with this feature request. We want use a build process where feature branches are auto-merged into the DEV branch after a successful build (TeamCity). For that to work we need to protect specific branches but allow read/write for other branches.

    The path and branch protection plugins are one of the features that differentiate SCM-Manager from the rest, and implementing this enhancement would make branch protection useful in many more scenarios.

  3. Sebastian Sdorra repo owner

    With version 1.2 of the branchwp-plugin it is possible to use "deny" permissions. With this version you protect only one branch by allowing all branches (*) and deny only a specific branch.

  4. Log in to comment