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

Re: [PATCH] fmt-patch: understand old <his> notation

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
May 6, 2006, 22:01 UTC
Message-ID
<Pine.LNX.4.63.0605062358280.6357@wbgn013.biozentrum.uni-wuerzburg.de>
In-Reply-To
<7viroirfur.fsf@assigned-by-dhcp.cox.net>
Hi,
On Sat, 6 May 2006, Junio C Hamano wrote:
Show 11 quoted lines
> Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
> 
> > When calling "git fmt-patch HEAD~5", you now get the same as if you would
> > have said "git fmt-patch HEAD~5..". This makes it easier for my fingers
> > which are so used to the old syntax.
> 
> While this would be easier on _my_ fingers as well, I have a
> suspicion that it might make more sense to make this "single
> ref" case to mean "HEAD~5^..HEAD~5" (if we _were_ designing a
> new command that is called format-patch today, that would be
> more natural).  But probably it is too late to break it by now.

No, it is not too late. I did this patch only to prevent cluttering my directory with millions of patches, only because I forgot _again_ to type the two dots.

Show 8 quoted lines
> > 	I wonder: would it make sense to make add_pending_object() and 
> > 	get_reference() in revision.c non-static?
> 
> I'd rather not expose such revision.c internals too much.  An
> alternative approach would be to give instruction to revision.c
> (read: another flag like rev.no_walk) to tell it to do something
> special when the user has only one commit, but I think what you
> did in your patch is cleaner and sufficient.

I just stole the function add_head() from builtin-diff.c, but that feels wrong. I think adding a pending object should not be internal to revision.c.

> Also we probably would want to default the diff options to show
> the root commit diff (rev.show_root_diff).
I gather this is needed for git-am/git-rebase to continue working?

Ciao, Dscho

Previous: Junio C HamanoNext: Junio C Hamano
Message 3 of 7 in “fmt-patch: understand old <his> notation”
  1. fmt-patch: understand old <his> notationJohannes Schindelin, May 6, 2006
  2. Junio C HamanoMay 6, 2006
  3. Johannes SchindelinMay 6, 2006
  4. Junio C HamanoMay 7, 2006
  5. Linus TorvaldsMay 6, 2006
  6. Olivier GalibertMay 6, 2006
  7. Junio C HamanoMay 7, 2006

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.