[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: git apologia

From: Eli Zaretskii
Subject: Re: git apologia
Date: Sun, 16 Nov 2014 18:06:17 +0200

> From: "Stephen J. Turnbull" <address@hidden>
> Date: Sun, 16 Nov 2014 01:25:30 +0900
> Cc: address@hidden
> Eli Zaretskii writes:
>  > The result is that I'm not even sure I figured out the "@address@hidden"
>  > spec correctly (did I?).
> You did.

Actually, it turns out neither this nor HEAD~n is what I want.  What I
want is to display information about commits N..M where N and M are
ordinal numbers from the linear "git log" output.  And waddaya know?
HEAD~n etc. seem to _skip_ merge-commits, so (a) the counts end up
being wrong, and (b) if you want to see those merge-commits, you need
to _know_ they are merge-commits and then use HEAD^2 etc. (i.e.
explicitly request the 2nd parent).  This is awful.

The result is that to simulate bzr's "diff -r-N..-M" functionality I
had to write a special-purpose alias, using "log --skip=N -nM -p -c",
in order to be able to display the diffs of a range of commits that
include merge-commits.  Ugh!  (Or maybe I missed some magic that
allows to do this with less pain.)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]