I have a project in which I ran git init. After several commits, I did git status which told me everything was up to date and there were no local changes.
Then I made several consecutive changes and realized I wanted to throw everything away and get back to my original state. Will this command do it for me?
git reset --hard HEAD
If you want to unleash your potential in this competitive field, please visit the DevOps course page for more information, where you can find the DevOps tutorials and DevOps frequently asked interview questions and answers as well.