Created
August 18, 2015 06:58
-
-
Save cescoffier/9ceacd1e422f89f6e186 to your computer and use it in GitHub Desktop.
A function deleting all git branches that have been merged into the current branch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function cleanup-branches | |
git branch --merged | grep -v "\*" | grep -v master | grep -v dev | xargs -n 1 git branch -d | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment