Skip to content

Instantly share code, notes, and snippets.

@patsma
Created March 2, 2021 01:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save patsma/5edeed92a7135834bc25f30e7760b8e8 to your computer and use it in GitHub Desktop.
Save patsma/5edeed92a7135834bc25f30e7760b8e8 to your computer and use it in GitHub Desktop.
When you think your git is messed up, you can use this command to do everything up-to-date.
git rm -r --cached .
git add .
git commit -am 'git cache cleared'
git push
Also to revert back last commit use this :
git reset HEAD^ --hard
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment