Skip to content

Instantly share code, notes, and snippets.

@luxifer
Last active August 29, 2015 14:02
Show Gist options
  • Save luxifer/50f9f5299324599aa822 to your computer and use it in GitHub Desktop.
Save luxifer/50f9f5299324599aa822 to your computer and use it in GitHub Desktop.
git branch clean
[alias]
branch-clean = !git remote prune origin && git branch --merged master | grep -v \"\\*\" | grep -v \"^[[:space:]]*master$\" | xargs -n 1 git branch -d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment