The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Close source branch does not delete the branch

Assaf Levy
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
March 2, 2022

Hey guys,

I would like a branch to be deleted automatically from git after its contents have been merged with the main branch, but it's not.

I'm using bitbucket in the cloud, on a repository where I have admin rights. I created a branch, did a commit, opened a pull request which I myself merged, all using the web interface.

At creation of the pull request I tick the "Delete X after the pull request is merged", and at merge I tick "Close branch after commit". The merge goes fine with no errors but the branch remains in git (not in the browser list though).

Any idea what am I missing?

Thanks in advance

1 answer

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

1 vote
Answer accepted
Ulrich Kuhnhardt _IzymesCo_
Atlassian Partner
March 2, 2022

When you say "remains in git" - do you mean in your local repository on your workstation?

If so - that would be normal, the remote (Bitbucket) will not make any changes on your and other users workstation.

You and others will have to 'clean up' local branches. I found this article very helpful.

Hope that helps,

Best, Ulrich

Izymes - We eliminate boring from work!

Assaf Levy
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
March 3, 2022

Hi Ulrich,

I found the problem based on the article you linked. I wasn't aware of pruning and apparently didn't have "auto-pruning" turned on. Now all works great.

Thank you very much!

Assaf

TAGS
AUG Leaders

Atlassian Community Events