going back to a certain commit
This question already has an answer here:
There are many ways to do this. If I were on master , the way I'd do it is as follows:
git branch safety to keep a branch at the old HEAD git reset --hard abc123 to move master back to the old commit, assuming that commit was abc123 git branch -D safety to discard the safety branch, if desired 上一篇: 重置Git分支到上次提交? 轨道
下一篇: 回到某个提交
