Skip to content

Instantly share code, notes, and snippets.

@asinghal
Created August 7, 2014 20:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save asinghal/1a609110c67a2eba7bb4 to your computer and use it in GitHub Desktop.
Save asinghal/1a609110c67a2eba7bb4 to your computer and use it in GitHub Desktop.
Clean up/ prune old Git branches
git remote prune origin
git checkout master && git branch --merged | grep -v master | sed -e 's/origin\///' | xargs git branch -d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment