Created
February 19, 2014 14:06
-
-
Save piotrbelina/9092770 to your computer and use it in GitHub Desktop.
remove all branches on remote already merged to master
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 | | |
grep origin | | |
grep -v '>' | | |
grep -v master | | |
grep -v vendor | | |
grep -v rtm | | |
xargs -L1 | | |
awk '{sub(/origin\//,"");print}' | | |
xargs git push -v origin --delete |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment