Skip to content

Instantly share code, notes, and snippets.

@AaronO
Created September 1, 2015 13:07
Show Gist options
  • Save AaronO/12af921e9d12931f5660 to your computer and use it in GitHub Desktop.
Save AaronO/12af921e9d12931f5660 to your computer and use it in GitHub Desktop.
A small utility script that remove merged branches it ignores current branch, master and gh-pages for security
#!/bin/sh
git branch --merged | grep -v "*" | grep -v master | grep -v gh-pages | xargs git branch -d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment