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

Re: [PATCH 1/2] format-patch: fix dashdash usage

From
Junio C Hamano <gitster@pobox.com>
Date
Nov 26, 2009, 19:57 UTC
Message-ID
<7vd4355aaw.fsf@alter.siamese.dyndns.org>
In-Reply-To
<1259262720-24077-2-git-send-email-felipe.contreras@gmail.com>
Felipe Contreras <felipe.contreras@gmail.com> writes:
> Otherwise 'git format-patch <committish> -- <non-existent-path>' doesn't
> work.
Instead of "doesn't work", I really wished you wrote something like:
    $ git format-patch <commit> -- <path>
    complains that <path> does not exist in the current work tree and the
    user needs to explicitly specify "--", even though the user _did_ give
    a "--".  This is because it incorrectly removes "--" from the command
    line arguments that is later passed to setup_revisions().

Remember that you are trying to help somebody who has to write Release Notes out of "git log" output.

I actually have a bigger question, though. Does it even make sense to allow pathspecs to format-patch? We sure are currently loose and take them, but I doubt it is by design.

The patch itself looks good and is a candidate 'maint' material, if the answer to the above question is a convincing "yes, because ...".

Previous: Felipe ContrerasNext: Felipe Contreras
Message 3 of 11 in “format-patch: fix dashdash”
  1. 0/2 format-patch: fix dashdashFelipe Contreras, Nov 26, 2009
  2. 1/2 format-patch: fix dashdash usageFelipe Contreras, Nov 26, 2009
  3. Junio C HamanoNov 26, 2009
  4. Felipe ContrerasNov 26, 2009
  5. Junio C HamanoNov 26, 2009
  6. Felipe ContrerasNov 26, 2009
  7. Junio C HamanoNov 27, 2009
  8. Felipe ContrerasNov 28, 2009
  9. Junio C HamanoNov 26, 2009
  10. Björn SteinbrinkNov 26, 2009
  11. 2/2 format-patch: add test for dashdashFelipe Contreras, Nov 26, 2009

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.