开发者

Get history/log of a (potentially removed) file in Git

How can I 开发者_如何学JAVAview history on a particular file (which may have been deleted already in the current trunk)?

Also, what diff tool do you suggest for mac?


Do this to view the history for a file, even if it has been deleted from the current HEAD:

git log -- <filename>

So if you deleted xyz.py a few revisions ago but would like to view its history, then you would do:

git log -- xyz.py


Also, what diff tool do you suggest for mac?

The Mac dev tools come with FileMerge, which is a decent diff tool. There's a command-line interface to it called opendiff (also ships with the dev tools).

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜