Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Git alias for removing stale branches that have already been merged into master
tidy = !git branch --merged master | grep -v 'master$' | xargs git branch -d && git remote | xargs -n 1 git remote prune
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment