Created
July 8, 2019 10:45
-
-
Save malhotrachetan/7832165067e0dba43bd8bcc45029c6a2 to your computer and use it in GitHub Desktop.
Script to clean your commit history from git
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 pull | |
git checkout --orphan temp_branch | |
git add -A | |
git commit -am "commit" | |
git branch -D master | |
git branch -m master | |
git push -f origin master |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment