Last active
May 14, 2021 11:42
-
-
Save inog/97ea0c724626114f43a6f5ed1e3d1dd1 to your computer and use it in GitHub Desktop.
delete local branches
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
//garbage collector | |
git gc | |
// alle remotes die keinen verbindung mehr zum server haben | |
git remote prune origin -n | |
// alle branches die nicht gemergt sind und nicht master|develop|\* heißen löschen | |
git branch | egrep -v "(master|develop|\*)"| xargs git branch -d | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment