Created
December 15, 2017 00:24
-
-
Save armincifuentes/fe781ccb522e4252dab4e030ef7947b4 to your computer and use it in GitHub Desktop.
Remove local branches not on master
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
git branch -r | awk '{print $1}' | egrep -v -f /dev/fd/0 <(git branch -vv | grep origin) | awk '{print $1}' | xargs git branch -d |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment