Created
September 3, 2015 09:25
-
-
Save kevinsimper/bba72c5431e3ebce9f62 to your computer and use it in GitHub Desktop.
Delete already merged remote branches easily
This file contains hidden or 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 --merged | \ | |
awk -F'/' '/^ *origin/{if(!match($0, /(>|master)/)){print $2}}' | \ | |
xargs git push origin --delete |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment