Skip to content

Instantly share code, notes, and snippets.

@dteoh
Created September 15, 2021 00:26
Show Gist options
  • Star 7 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dteoh/575c3a5a6025ac2591d2062243a4e2a3 to your computer and use it in GitHub Desktop.
Save dteoh/575c3a5a6025ac2591d2062243a4e2a3 to your computer and use it in GitHub Desktop.
Interactively delete git branches locally

Delete multiple Git branches with a UI

This assumes you have installed fzf.

$ git branch --no-color | fzf -m | xargs -I {} git branch -D '{}'

Press tab to mark a branch, shift-tab to unmark. Press enter and all marked branches will be deleted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment