Why is "Close branch after the pull request is merged" disabled?

Using Mecurial+Bitbucket.

When creating a pull request from fork1 branch1, to the parent repository's default branch, the "Close branch after the pull request is merged" option is disabled.

Why's that?

2 answers

If you are pulling a request across branches, you can have the option to close the branch when your request is merged. Whether you have this option depends on whether the repository is Git or Mercurial. Mercurial repositories always have this option. Git repositories have this option if the repo administrator allows it; Otherwise, the option is greyed out.

This is in the Bitbucket documentation on this page: https://confluence.atlassian.com/display/BITBUCKET/Work+with+pull+requests</span<>>

Thanks Mary,

I am pulling across branches, and the repository is Mercurial, yet the option is still greyed out.

Does it make a difference that I'm pulilng from a different fork as well as a different branch?

The reason it is grey out is because you prevented bookmark deletion. This seems to be a bug, as the documentation states that "you can also prevent users from deleting branches (Git) or bookmarks (Mercurial)", which might be equating branches with bookmarks, even though the Branch Management page states the following: "These rules only apply to bookmarks. Users can still close a branch; closing a branch does not remove it from history."

I've added an issue about this problem.

Suggest an answer

Log in or Join to answer
Community showcase
Piotr Plewa
Published Dec 27, 2017 in Bitbucket

Recipe: Deploying AWS Lambda functions with Bitbucket Pipelines

Bitbucket Pipelines helps me manage and automate a number of serverless deployments to AWS Lambda and this is how I do it. I'm building Node.js Lambda functions using node-lambda&nbsp...

710 views 0 4
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot