Created
September 5, 2018 12:34
-
-
Save daniele-athome/6761791af38c09b4071fca4858e13344 to your computer and use it in GitHub Desktop.
Delete orphan commits https://tekkie.ro/news/howto-remove-all-dangling-commits-from-your-git-repository/
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
#!/bin/sh | |
git reflog expire --expire=now --all | |
git gc --prune=all --aggressive |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment