Skip to content

Instantly share code, notes, and snippets.

@Anks
Created June 22, 2022 04:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Anks/db175b31f173ec2821b0640c496dff3a to your computer and use it in GitHub Desktop.
Save Anks/db175b31f173ec2821b0640c496dff3a to your computer and use it in GitHub Desktop.
Delete all merged branches from your local git repository
git branch --merged | grep -v master | grep -v main | xargs git branch -d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment