2

We are using GitFlow workflow. After merging the release/* branch to master, we need to close the branch. For this task, we need to provide deletion access to pull request merger but in this case, merger can delete the release/* branch any time.

Do we have any option to restrict the branch closer only after it is merged to some other branch ?

1

You should not delete the branches at all. Just rename them to stale!

but

As of Bitbucket 7.3 there is an option to delete branches automatically after merge. Just prevent deletion at all, set the other option and you are done.

2
  • Any specific reason, why we should not delete the merged branches? Jun 7 at 10:12
  • That is what you are faced with. "restrict the branch closer only after merge". If you don't delete them, you don't have to. If you state them as "stale" you can easily see what change came from what branch. If anything is wrong, in the (far) future, you can correct that in the "stale" branch and connect the changes/fix to the affecting branch.
    – David
    Jun 8 at 11:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.