Last active
May 13, 2020 04:49
-
-
Save waynedovey/37b9a897c83ddd4e178fc1b5f815ea1c to your computer and use it in GitHub Desktop.
Clean out the Git History if you have checked in a password by mistake
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
# Feature Branch | |
git checkout --orphan fixit | |
git add -A | |
git commit -m "update" | |
git branch -D feature/bastion-create | |
git branch -m feature/bastion-create | |
git push -f origin feature/bastion-create | |
git gc --aggressive --prune=all | |
# Master Branch | |
git checkout --orphan fixit | |
git add -A | |
git commit -m "update" | |
git branch -D master | |
git branch -m master | |
git push -f origin master | |
git gc --aggressive --prune=all |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment