假设我有一个名为
Development
的分支,并从中派生出分支 Items/Feature_A
。我致力于 Feature_A
做出多项承诺。 Development
然后其他分支对其进行了多次提交。我现在想看看 Feature_A
中的最新提交与从 Development
上派生的点之间的区别 - 有没有办法做到这一点,而不必查找/猜测 Development
上的提交?
我正在使用 Visual Studio 2022,希望有一个类似于现在选择分支、调出分支菜单、右键单击另一个分支并选择“与当前分支比较...”的功能,只是如果我在我已经所在的分支上执行此操作,我希望找到“与基础比较...”。
从命令行,那就是:
git diff Development...Feature_A # <- three dots
# or:
git diff Development...HEAD # <- if Feature_A is your active branch
# or:
git diff Development... # <- short for 'Development...HEAD'
我不了解 Visual Studio 及其 GUI,如果您有办法在 GUI 字段之一中键入传递给
git diff
的字符串,则可以键入 Development...