Last active
March 4, 2016 12:57
-
-
Save janbaer/3c08a2039c1363dce2ba to your computer and use it in GitHub Desktop.
Purges all remote deleted feature branches locally
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 Git-Purge () { | |
git fetch -p | git branch --color=never --merged | grep -v "\*" | grep -v "master" | grep -v "develop" | xargs -n 1 git branch -d | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I just update the git branch part with the --color=never arguments because of problems with the color ansi codes.