Home > Mobile >  How do I undo the most recent commits in Git?
How do I undo the most recent commits in Git?

Time:01-03

I am not able to undo the commits in git. It shows technical errors while doing so.

I have tried to navigate to the folder for my git repo and expecting to solve the problem at the earliest.

CodePudding user response:

This post has explained undoing commits previously, presuming the issue is sourced in your local repository.

Link: How do I undo the most recent local commits in Git?

CodePudding user response:

command:

git revert HEAD

you can mention the commit ID to revert the commit, if mentioned HEAD it will revert the last commit

  • Related