Re: Our merge bases sometimes suck
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jun 13, 2014, 22:35 UTC
- Message-ID
- <xmqqbntw1lqx.fsf@gitster.dls.corp.google.com>
- In-Reply-To
- <539B1E59.1030604@gmail.com>
Jakub Narębski <jnareb@gmail.com> writes:
Show 14 quoted lines
> I don't know if it has been fixed, but there is a difference > between "git diff A...B" when A and B have one merge base, and > "git diff A...B" when there are more than one merge base. > > When there is one merge base, "git diff A...B" returns simple > unified diff equivalent to "git diff $(git merge-base A B) B". > It is unsymmetric. > > But where there are more than one merge base, by design or by > accident for "git diff A...B" git 1.9.2 / 1.7.4 returns > > git diff --cc $(git merge-base --all A B) A B > > which is *symmetric*, and is combined not unified diff.
Hmph, the relevant code has not changed very much since c008c0ff (diff A...B: give one possible diff when there are more than one merge-base, 2010-07-12) which has been with us since v1.7.2.