Last active
December 29, 2016 21:06
-
-
Save arkiver/b2d0b1da43c48a2800ea to your computer and use it in GitHub Desktop.
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
# Destructive! Use carefully. | |
# merged branches | |
((`git branch --merge master`).strip!.split(' ') - ['master', 'release']).map{ |b| `git branch -D "#{b}"; git push origin :"#{b}"` } | |
# All local branches | |
((`git branch`).strip!.split(' ') - ['master', 'release', 'development']).map{ |b| `git branch -D "#{b}"; git push origin :"#{b}"` } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment