Re: How to find commits unique to a branch
- From
Nikolaus Rath <nikolaus@rath.org>
- Date
- Jun 20, 2016, 23:21 UTC
- Message-ID
- <87lh1z78fr.fsf@thinkpad.rath.org>
- In-Reply-To
- <xmqqtwgnsdr3.fsf@gitster.mtv.corp.google.com>
On Jun 20 2016, Junio C Hamano <gitster@pobox.com> wrote:
Show 11 quoted lines
> Nikolaus Rath <Nikolaus@rath.org> writes: > >> What's the best way to find all commits in a branch A that have not been >> cherry-picked from (or to) another branch B? >> >> I think I could format-patch all commits in every branch into separate >> files, hash the Author and Date of each files, and then compare the two >> lists. But I'm hoping there's a way to instead have git do the >> heavy-lifting? > > "git cherry" perhaps?
That seems to work only the "wrong way around". I have a tag fuse_3_0_start, which is the common ancestor to "master" and "fuse_2_9_bugfix". I'd like to find all the commits from fuse_3_0_start to master that have not been cherry-picked into fuse_2_9_bugfix.
However:
* "git cherry fuse_3_0_start master release2.9" tells me nothing has been cherry-picked at all (only lines with +)
* "git cherry fuse_3_0_start release2.9 master" also tells me nothing has been cherry picked, but somehow shows a smaller total number of commits.
* "git cherry master release2.9 fuse_3_0_start" gives me the commits from fuse_2_9_bugfix that have not been cherry-picked into master (which seems to be in contradiction to the two earlier commands).
Am I missing something obvious?
Best, -Nikolaus
--
GPG encrypted emails preferred. Key id: 0xD113FCAC3C4E599F
Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
»Time flies like an arrow, fruit flies like a Banana.«