Skip to content

Instantly share code, notes, and snippets.

@RafalSladek
Created May 7, 2019 14:51
Show Gist options
  • Save RafalSladek/53b850896630e9cf101e2f96f026e3e4 to your computer and use it in GitHub Desktop.
Save RafalSladek/53b850896630e9cf101e2f96f026e3e4 to your computer and use it in GitHub Desktop.
Remove all your local git branches but keep master
#!/bin/bash
git branch | grep -v "master" | xargs git branch -D
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment