how to show log for only one branch

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

 



I'm some confused by `git log', here is a revision graph:

a-----> b ---> c ----------------> f ---> g --- master
        \                        /
         `------> d ----------> e ---- test

I hope `git log ...` shows g, f, c, b, a.

`git log master` shows g, f, e, d, c, b, a;
`git log master ^test` shows g, f, c.
`git log --no-merges master` shows g, e, d, c, b, a.

That's to say, I want to view master, master~1, master~2, master~3, ...
until the beginning, no commits in other branches involved.

I have heard git treats all parents equally in a merge operation, so I
am curious how git decides which parent is HEAD^1.

I feel the HEAD^1 branch is more special than HEAD^2 branch, because HEAD^1
is usually the working branch and the target branch of merging operation.
it's a little more convenient to see only commits that really happen in
current branch, especially for people who come from CVS and Subversion (yes,
I think git is more interesting than CVS and Subversion:-).

-
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]