Confusion about diffing branches

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

 



So I imagine I'm missing something, or perhaps I'm just looking at this
from the wrong perspective, but here is what I'm seeing.  Lets say I
have something like:

         A---B topic
        /
   C---D---E master

If I want to see a diff of all of the changes between the two branches I
can say:

   git diff master topic

Which shows me the combined diff of commits A, B and E.  That is exactly
what I would expect however, I would expect that equivalently I could
say:

   git diff master...topic

to see all commits reachable from topic and master but not both.
However, this doesn't do what I expect but instead only shows me the
combined diff of A and B.  Likewise:

   git diff topic...master

Shows me the diff of E.  Am I crazy or isn't this supposed to be the
behavior of the topic..master notation?  Strangely enough running either

   git diff master..topic
   git diff topic..master

both show me the diff of A, B and E, which is what I would expect from
the master...topic notation.  Am I the only one who thinks this is
backwards?  The same experiment using git log shows me what I would
expect so somehow I think I'm missing something.
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux