Last Updated: February 25, 2016
·
621
· bartekfi

Delete branches already merged to master

If you want to clean up your repository and remove all branches that are already merged to master, use this command:

git branch --merged | grep -v "\*" | xargs -n 1 git branch -d

source: http://stackoverflow.com/questions/6127328/how-can-i-delete-all-git-branches-which-are-already-merged