git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: How can I easily verify my diffs are in parent branch?

From
Junio C Hamano <junkio@cox.net>
Date
Apr 5, 2007, 05:25 UTC
Message-ID
<7vircbwfym.fsf@assigned-by-dhcp.cox.net>
In-Reply-To
<Pine.LNX.4.64.0704040744160.6730@woody.linux-foundation.org>
Linus Torvalds <torvalds@linux-foundation.org> writes:
Show 11 quoted lines
> So to compare all patch-ID's, you can do
>
> 	git cherry cvs-upstream my-branch
>
> adn it should look at all the commits that are in *your* branch but not 
> upstream, and report their ID's preceded by a "-" if they are upstream, 
> and a "+" if they are not.
>
> You can then look at the "+" commits more closely, to see whether maybe 
> they actually did get merged, but got changed/fixed in the process, or 
> whether they really are missing.
Funny.

Last night I was thinking about git-cherry, as it is one of the few commands that have "funny parameter semantics that do not mesh well with git-log family" (others are format-patch and rebase).

I think we should be able to use --left-right and ... operator to express what the above cherry does with something like:

    $ git log --left-right --ignore-common-patch cvs-upstream...my-branch

The --ignore-common-patch option does not exist yet, but the basic code to implement it should already be accessible from the log family, as that is what format-patch needs to do.

Previous: Linus TorvaldsNext: David Kågedal
Message 5 of 19 in “How can I easily verify my diffs are in parent branch?”
  1. Alex BenneeApr 4, 2007
  2. Alex RiesenApr 4, 2007
  3. Andy ParkinsApr 4, 2007
  4. Linus TorvaldsApr 4, 2007
  5. Junio C HamanoApr 5, 2007
  6. David KågedalApr 5, 2007
  7. Junio C HamanoApr 5, 2007
  8. Document --left-right option to rev-list.Brian Gernhardt, Apr 5, 2007
  9. Junio C HamanoApr 5, 2007
  10. Alex RiesenApr 7, 2007
  11. 1/2 git-log --cherry-pickJunio C Hamano, Apr 9, 2007
  12. 1/4 Add %m to '--pretty=format:'Junio C Hamano, Apr 10, 2007
  13. 2/4 Refactor patch-id filtering out of git-cherry and git-format-patch.Junio C Hamano, Apr 10, 2007
  14. Johannes SchindelinApr 14, 2007
  15. 3/4 git-log --cherry-pick A...BJunio C Hamano, Apr 10, 2007
  16. 4/4 Documentation: --cherry-pickJunio C Hamano, Apr 10, 2007
  17. 2/2 Add %m to '--pretty=format:'Junio C Hamano, Apr 9, 2007
  18. Alex BenneeApr 11, 2007
  19. Linus TorvaldsApr 11, 2007

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.