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

Re: [PATCH 1/4] parse-options: convert "command mode" to a flag

From
Paolo Bonzini <pbonzini@redhat.com>
Date
Feb 19, 2020, 21:05 UTC
Message-ID
<ea9395db-b39a-358f-df8e-b28907193415@redhat.com>
In-Reply-To
<xmqqzhdee6c6.fsf@gitster-ct.c.googlers.com>
On 19/02/20 20:15, Junio C Hamano wrote:
Show 12 quoted lines
>> OPTION_CMDMODE is essentially OPTION_SET_INT plus the extra check
>> that the variable had not set before.  In order to allow custom
>> processing, change it to OPTION_SET_INT plus a new flag that takes
>> care of the check.  This works as long as the option value points
>> to an int.
> It is unclear but I am guessing that the purpose of this change is
> to make "only one of these" orthgonal to "the value of this option
> is an int", in preparation to allow options other than SET_INT to
> also be combined with "only one of these"?
> 
> If my reading is not correct, that would be an indication that the
> above paragraph does not tell what it wants to to readers.  

Your reading and your conclusion are both correct. I'll reword the commit message.

Paolo
> It is unclear at this step what other kind of option the flag wants
> to be combined, though.
> 
Previous: Junio C HamanoNext: pbonzini@redhat.com
Message 6 of 15 in “am: provide a replacement for "cat .git/rebase-apply/patch"”
  1. 0/4 am: provide a replacement for "cat .git/rebase-apply/patch"pbonzini@redhat.com, Feb 19, 2020
  2. 1/4 parse-options: convert "command mode" to a flagpbonzini@redhat.com, Feb 19, 2020
  3. Eric SunshineFeb 19, 2020
  4. Johannes SchindelinFeb 20, 2020
  5. Junio C HamanoFeb 19, 2020
  6. Paolo BonziniFeb 19, 2020
  7. 2/4 am: convert "resume" variable to a structpbonzini@redhat.com, Feb 19, 2020
  8. Junio C HamanoFeb 19, 2020
  9. Paolo BonziniFeb 19, 2020
  10. 3/4 am: support --show-current-patch=raw as a synonym for--show-current-patchpbonzini@redhat.com, Feb 19, 2020
  11. Eric SunshineFeb 19, 2020
  12. Junio C HamanoFeb 19, 2020
  13. Paolo BonziniFeb 19, 2020
  14. 4/4 am: support --show-current-patch=diff to retrieve .git/rebase-apply/patchpbonzini@redhat.com, Feb 19, 2020
  15. Eric SunshineFeb 19, 2020

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.