Created
August 24, 2021 15:44
-
-
Save mgrahamjo/51be9fb82e52f9020632551f69680738 to your computer and use it in GitHub Desktop.
Deletes all local branches that have been pushed to the remote
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git branch -r | grep -v origin/main | sed 's#origin/##' | xargs git branch -D 2>/dev/null |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment