git go back to previous commit in project code example
Example 1: how to revert to log in git
git revert --no-commit 0766c053..HEAD
git commit
Example 2: reset to commit
# rollback to commit state
git revert --no-commit 0766c053..HEAD
git commit