Skip to content

Instantly share code, notes, and snippets.

@qwertme
Created May 9, 2018 19:52
Show Gist options
  • Save qwertme/a0e971b39070574627f03cf4423d1dd1 to your computer and use it in GitHub Desktop.
Save qwertme/a0e971b39070574627f03cf4423d1dd1 to your computer and use it in GitHub Desktop.
Delte remote branches
git fetch --prune | git branch -r --merged | grep origin | grep -v '>' | grep -v master | sed -E "s|^ *origin/||g" | xargs git push origin --delete
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment