Skip to content

Instantly share code, notes, and snippets.

@ribase
Created May 7, 2019 07:48
Show Gist options
  • Select an option

  • Save ribase/1ecf22fd936ce249feffef1b4e0e33fb to your computer and use it in GitHub Desktop.

Select an option

Save ribase/1ecf22fd936ce249feffef1b4e0e33fb to your computer and use it in GitHub Desktop.
this bash command will remove all merged branches
git branch --format="%(refname:lstrip=2)" --merged | xargs git branch -d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment