git checkout doesn show previous commit code example Example: git checkout commit git checkout <commit>