From the magit-status buffer, if I hit b k it will bring up a list of branches with helm-mode-magit-branch-delete. If I select a branch and hit RET, it will delete that branch (sometimes prompting to make sure that is what I want to do if the branch is unmerged).

What I am looking for is a way to delete multiple branches.

The documentation from magit-branch-delete says

Delete one or multiple branches. If the region marks multiple branches, then offer to delete those, otherwise prompt for a single branch to be deleted, defaulting to the branch at point.

However, from helm-mode-magit-branch-delete, I am not sure how to select multiple branches. I have tried using C-SPC (helm-toggle-visual-mark), which visually marks the branches I wan't, but when I hit RET with multiple branches marked, it only deletes the branch at point. I can't seem to find documentation for helm-mode-magit-branch-delete, and am out of ideas as to how to delete multiple branches. Any suggestions?

Also, as suggested in the comments below, I am not sure thathelm-mode-magit-branch-delete is an actual command since I can't find it documented or referenced anywhere else, but it is the name of the buffer when I try to call magit-delete-branch from the magit-status-buffer, so this was the only way I new to reference it. From my modeline:

enter image description here

  • I cannot even find the definition of helm-mode-magit-branch-delete. Are you sure such a command really exists? In what package is it defined?
    – tarsius
    Commented Dec 22, 2015 at 16:53
  • @tarsius I also couldn't find documentation for this "command" or find where the interactions between helm and magit are defined, but helm seems to have taken over many of my magit commands - basically anywhere where something needs to be selected from a list, helm takes over.
    – elethan
    Commented Dec 22, 2015 at 17:08
  • 1
    I think that's the name of the buffer with the completion candidates, not the name of the function used populate that buffer.
    – tarsius
    Commented Dec 23, 2015 at 13:13

1 Answer 1


The doc-string you quote talks about marking multiple branches in a Magit buffer, not during Helm completion.

You can show a buffer which lists all branches and tags using y. In that buffer you can mark multiple branches using the region. Then press k to delete them. You'll be asked if you really want to do so.

Magit does not support marking non-consecutive sections dired-style.

  • This is exactly what I wanted, and I appreciate being asked for confirmation even when branches have been merged, because the previous method I was using would not offer such confirmation. I have no problem selecting multiple branches this way using the region as you suggested, but is there by any chance a way to mark multiple non-consecutive branches? I have tried a few things and looked at the documentation, and it doesn't seem like I can do that, but I thought if anyone would know you would! : )
    – elethan
    Commented Dec 22, 2015 at 17:05
  • No, that's not supported.
    – tarsius
    Commented Dec 23, 2015 at 13:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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