Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Cleans stale git branches (removed on remote and merged local branches)
git remote prune origin
git branch --merged | egrep -v "(^\*|master|dev)" | xargs -r git branch -d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment