Created
January 23, 2014 19:59
-
-
Save rminderhoud/8585717 to your computer and use it in GitHub Desktop.
Delete multiple remote branches
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 -Forigin/ '/PATTERN/ {print $2}' | xargs -I {} git push origin :{} | |
check which branches going to delete | |
git branch -r | awk -Forigin/ '/PATTERN/ {print $2}' | |
Source: http://stackoverflow.com/questions/10555136/delete-multiple-remote-branches-in-git#answer-13974015 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment