Reset or revert a specific file to a specific revision using Git?
本问题已经有最佳答案,请猛点这里访问。
给定下面互动: </P >
1 2 3 | $ git add foo $ git commit -m"Initial import of 'foo'" $ rm foo # This could be any destructive action on foo, like editing it. |
怎么在恢复"foo"在我的工作拷贝吗?我在找什么东西似的: </P >
1 2 | $ git <magic> foo Restored foo to revision <blah>. |