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

Re: [PATCH v13 2/6] test-parse-options: print quiet as integer

From
Pranit Bauva <pranit.bauva@gmail.com>
Date
Apr 12, 2016, 22:16 UTC
Message-ID
<CAFZEwPPSY+k9qc8hZ685o9_U3UktbgK-e00zrG2+7GehG-47dQ@mail.gmail.com>
In-Reply-To
<xmqq60vmpl5c.fsf@gitster.mtv.corp.google.com>
On Wed, Apr 13, 2016 at 3:03 AM, Junio C Hamano <gitster@pobox.com> wrote:
Show 21 quoted lines
> Pranit Bauva <pranit.bauva@gmail.com> writes:
>
>> Current implementation of parse-options.c treats OPT__QUIET() as integer
>> and not boolean and thus it is more appropriate to print it as integer
>> to avoid confusion.
>
> There is no "confusion" factor involved, as we do not use native
> "boolean" type in our C code.  IIUC, the reason why we want to do
> this is because we may want to see how it would affect the value of
> the underlying variable to give multiple --quiet options from the
> command line, which is a policy issue (i.e. we want to allow
> commands to react to multiple quiet options differently), not an
> implementation one (i.e. "current implementation happens to use
> integer").
>
>         We would want to see how multiple --quiet options affect the
>         value of the underlying variable (we may want "--quiet --quiet"
>         to still be 1, or we may want to see the value incremented
>         to 2).  Show the value as integer to allow us to inspect it.
>
> perhaps?

This commit message does look a lot better. I will re-roll this. Should I just send an update of this patch or the whole series?

Previous: Junio C HamanoNext: Junio C Hamano
Message 33 of 36 in “t0040-test-parse-options.sh: fix style issues”
  1. 1/5 t0040-test-parse-options.sh: fix style issuesPranit Bauva, Apr 2, 2016
  2. 3/5 parse-options.c: make OPTION_COUNTUP respect "unspecified" valuesPranit Bauva, Apr 2, 2016
  3. Eric SunshineApr 3, 2016
  4. Pranit BauvaApr 5, 2016
  5. 2/5 test-parse-options: print quiet as integerPranit Bauva, Apr 2, 2016
  6. Eric SunshineApr 3, 2016
  7. Pranit BauvaApr 5, 2016
  8. Eric SunshineApr 6, 2016
  9. Duy NguyenApr 8, 2016
  10. Junio C HamanoApr 8, 2016
  11. 4/5 t7507-commit-verbose: improve test coverage by testing number of diffsPranit Bauva, Apr 2, 2016
  12. Eric SunshineApr 4, 2016
  13. Eric SunshineApr 4, 2016
  14. Pranit BauvaApr 5, 2016
  15. 5/5 commit: add a commit.verbose config variablePranit Bauva, Apr 2, 2016
  16. Eric SunshineApr 4, 2016
  17. Eric SunshineApr 4, 2016
  18. Pranit BauvaApr 5, 2016
  19. Eric SunshineApr 3, 2016
  20. Pranit BauvaApr 4, 2016
  21. Eric SunshineApr 4, 2016
  22. Pranit BauvaApr 5, 2016
  23. 1/6 t0040-test-parse-options.sh: fix style issuesPranit Bauva, Apr 9, 2016
  24. 6/6 commit: add a commit.verbose config variablePranit Bauva, Apr 9, 2016
  25. Junio C HamanoApr 12, 2016
  26. Pranit BauvaApr 12, 2016
  27. Junio C HamanoApr 12, 2016
  28. Junio C HamanoApr 12, 2016
  29. Pranit BauvaApr 12, 2016
  30. 5/6 t7507-commit-verbose: improve test coverage by testing number of diffsPranit Bauva, Apr 9, 2016
  31. 2/6 test-parse-options: print quiet as integerPranit Bauva, Apr 9, 2016
  32. Junio C HamanoApr 12, 2016
  33. Pranit BauvaApr 12, 2016
  34. Junio C HamanoApr 12, 2016
  35. 3/6 t0040-parse-options: improve test coveragePranit Bauva, Apr 9, 2016
  36. 4/6 parse-options.c: make OPTION_COUNTUP respect "unspecified" valuesPranit Bauva, Apr 9, 2016

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.