I got confused with Git !!
I have some files which have added and committed to master branch before.
NOw, I’ve made some changes in some files,but before adding and committing these modifications, I just want to abandon whatever I’ve done and come back to my previous , peaceful, state !!
What was the command ??
If the files are on the staging area (you
git added them):If they are on the working area:
I also suggest giving Adam Dymitruk’s answer a look (at least the first part). He explains how to save your changes before canceling them.