# as the best wat to revert back 3 commits git revert HEAD~3 git restore #to restore files from commit