Skip to content

Instantly share code, notes, and snippets.

@syabro
Created February 22, 2016 12:33
Show Gist options
  • Save syabro/003dc51f6f42ea8d8572 to your computer and use it in GitHub Desktop.
Save syabro/003dc51f6f42ea8d8572 to your computer and use it in GitHub Desktop.
Remove stale branches
git fetch -p; for branch in `git branch -vv | grep ': gone]' | gawk '{print $1}'`; do git branch -d $branch; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment