Urgent! How to undo git pull misoperation? Accidentally git pulled. . . . .
If there is no conflict, just switch to the submission you need.
git reset --hard
You can go back to the previous version
Use the git reflog command to view your historical change records, Then you can use git reset --hard HEAD@{n}, (n is the reference position you want to roll back to) to roll back.
If there is no conflict, just switch to the submission you need.
You can go back to the previous version
Use the git reflog command to view your historical change records,
Then you can use git reset --hard HEAD@{n}, (n is the reference position you want to roll back to) to roll back.