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

Re: [PATCH] Check for -amend as a common wrong usage of --amend.

From
Junio C Hamano <gitster@pobox.com>
Date
Jan 26, 2008, 06:20 UTC
Message-ID
<7vd4rp3y6e.fsf@gitster.siamese.dyndns.org>
In-Reply-To
<20080124204711.GC17765@kodama.kitenet.net>
Joey Hess <joey@kitenet.net> writes:
Show 11 quoted lines
> Some option parsers avoid this sort of ambiguity by not allowing short
> options that take a string to be bundled in the same word with other
> short options.
>
> So, for example, git-commit -am<msg> would not be allowed, while
> git-commit -a -m<msg> and perhaps git-commit -am <msg> would be allowed.
>
> There could still be problems if there were a --mend option that could
> be typoed as -mend.
>
> I don't know enough about compatability to say if this would work for git.
Yeah, I think that is quite a sensible workaround.
Previous: Joey HessNext: Pierre Habouzit
Message 9 of 11 in “Check for -amend as a common wrong usage of --amend.”
  1. Check for -amend as a common wrong usage of --amend.Pascal Obry, Jan 24, 2008
  2. Pascal ObryJan 24, 2008
  3. Jörg SommerJan 26, 2008
  4. Johannes SchindelinJan 24, 2008
  5. Pascal ObryJan 24, 2008
  6. Charles BaileyJan 24, 2008
  7. Pascal ObryJan 24, 2008
  8. Joey HessJan 24, 2008
  9. Junio C HamanoJan 26, 2008
  10. Pierre HabouzitJan 26, 2008
  11. parse-options: catch some likely in presense of aggregated options.Pierre Habouzit, Jan 26, 2008

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.