git diff <local branch> <remote>/<remote branch>
For example git diff master origin/master
, or git diff featureA origin/next
(例如git diff master origin/master
,或git diff featureA origin/next
)
Of course to have said remote-tracking branch you need to git fetch
first;
(当然, 曾经说过,你需要远程跟踪分支 git fetch
第一;)
and you need it to have up to date information about branches in remote repository. (并且您需要它以获得有关远程存储库中分支的最新信息。)
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…