Skip to content

Instantly share code, notes, and snippets.

@sr2ds
Created May 4, 2020 13:05
Show Gist options
  • Save sr2ds/7e8d3136e950a7878a14f7a89047afdb to your computer and use it in GitHub Desktop.
Save sr2ds/7e8d3136e950a7878a14f7a89047afdb to your computer and use it in GitHub Desktop.
git Remove merged local branch
#!/bin/bash
git branch --merge | grep -v develop| grep -v master | awk '{ print $1 }'| while read branch; do git branch -D $branch; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment