branch from previous commit code example
Example 1: git checkout previous commit
git reset --hard HEAD~10
To rollback 10 commits back:
Example 2: git go back to previous commit
git checkout 12feg3435 #commit ID
git reset --hard HEAD~10
To rollback 10 commits back:
git checkout 12feg3435 #commit ID