问题:
Possible Duplicate: 可能重复:
How do I show the changes which have been staged? 如何显示已上演的更改?
Is there a way I can see the changes that were made to a file
after I have done git add file
? 有没有办法可以看到我完成git add file
后对file
所做的更改?
That is, when I do: 也就是说,当我这样做时:
git add file
git diff file
no diff is shown. 没有显示差异。 I guess there's a way to see the differences since the last commit but I don't know what that is. 我想有一种方法可以看到自上次提交以来的差异,但我不知道那是什么。
解决方案:
参考一: https://stackoom.com/question/Enku/在暂存区域中显示文件中的git-diff-复制参考二: https://oldbug.net/q/Enku/Show-git-diff-on-file-in-staging-area-duplicate
来源:oschina
链接:https://my.oschina.net/stackoom/blog/4319692