How can I reset or revert a file to a specific revision?

前端 未结 30 1945
不思量自难忘°
不思量自难忘° 2020-11-21 11:23

I have made some changes to a file which has been committed a few times as part of a group of files, but now want to reset/revert the changes on it back to a previous versio

30条回答
  •  日久生厌
    2020-11-21 11:33

    I have to plug EasyGit here, which is a wrapper to make git more approachable to novices without confusing seasoned users. One of the things it does is give more meanings to git revert. In this case, you would simply say:

    eg revert foo/bar foo/baz

提交回复
热议问题