Skip to content

Instantly share code, notes, and snippets.

@boopathi
Last active Jan 13, 2018
Embed
What would you like to do?
Cleanup git branches
#!/bin/bash
git branch -r |
awk '{print $1}' |
egrep -v -f /dev/fd/0 <(git branch -vv | grep origin) |
awk '{print $1}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment