Join the Stack Overflow Community
Stack Overflow is a community of 6.5 million programmers, just like you, helping each other.
Join them; it only takes a minute:
Sign up

Is there an option to delete a branch with TortoiseGit?

I found a solution for the commandline. Is there an implementation in TortoiseGit?

share|improve this question
up vote 205 down vote accepted

You should read this article: Remote branches with TortoiseGit

According to this blog post:

...remove the local branch by first opening up the Checkout/Switch dialog to get at the Browse refs dialog.

enter image description here

In the Browse refs dialog we can right click on the local branch and choose to delete it.

enter image description here

To delete a remote branch we can do the same thing, but instead of right clicking on our local branch we expand the remotes tree in the left part of the dialog and then locate the remote branch.

enter image description here

share|improve this answer
4  
Btw. please be aware that you cannot delete the branch you are currently on (this will give an error). Also if the branch you want to delete is not visible in the "Browse references" dialog it may have been created recently, do a pull before. And finally there is a direct way to get to "Browse references". See other answer by Razvan Panda. – Trilarion Sep 9 '14 at 20:00
2  
Great answer! But this option needs a better place in TortoiseGit gui, it's sorta 'hidden' now... – Stijn de Witt Sep 23 '14 at 11:32

You can Shift + Right Click on the cloned repository and choose Browse References from TortoiseGit submenu:

Click on remotes in the left tree view, and then right click the branch you wish to remove and click on Delete remote branch.

You can also get rid of the "shift"+right click: Go to TortoiseGit settings -> "Set extended context menu" and uncheck "Browse References"

share|improve this answer
5  
You can also get rid of the "shift"+right click: Go to TortoiseGit settings -> "Set extended context menu" and uncheck "Browse References" – MrTux Mar 29 '15 at 4:24

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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