(no title)
henshao | 1 year ago
https://stackoverflow.com/questions/7726949/remove-tracking-...
git fetch -p && git branch -vv | awk '/: gone]/{print $1}' | xargs git branch -dhenshao | 1 year ago
https://stackoverflow.com/questions/7726949/remove-tracking-...
git fetch -p && git branch -vv | awk '/: gone]/{print $1}' | xargs git branch -d
n4r9|1 year ago
The script in OP handles that edge case by switching to the main branch before deleting. That may or may not be intuitive but I think it's a reasonable response. The script also prints error messages for various other bad inputs. Once you strip all that out it's only a few lines long.
henshao|1 year ago
ashconnor|1 year ago