Working ...
About
Contact
search
Dblock.org
@dblockdotorg
My Github
p
|
s
|
pics
|
me
|
list
Git: Deleting Merged Branches
Back
|
git
|
6/9/2011
|
Tweet
git branch --merged | grep -v master | xargs git branch -d
git branch -r --merged | awk -F'/' '/^ *origin/{if(!match($0, /(>|master)/)){print $2}}' | xargs git push origin --delete
Here’s the same in
a Gist
for you to comment and improve.
Please enable JavaScript to view the
comments powered by Disqus.