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

Re: [PATCH] chainlint: colorize problem annotations and test delimiters

From
Jeff King <peff@peff.net>
Date
Sep 13, 2022, 01:34 UTC
Message-ID
<Yx/eG5xJonNh7Dsz@coredump.intra.peff.net>
In-Reply-To
<CAPig+cRTatQRS2MyOTfmz56UKqtz_x_Gk6j=rnYR-jTkM-CDdQ@mail.gmail.com>
On Mon, Sep 12, 2022 at 08:30:02PM -0400, Eric Sunshine wrote:
Show 6 quoted lines
> This is indeed a lot of new processes, but this color interrogation is
> done lazily, only if a problem is detected, so it should be zero-cost
> in the (hopefully) normal case of a lint-clean script.
> 
> I had the exact same thought about the cost being paid by test-lib.sh
> making all those `tput` invocations.
Ah, right, that's even better.

I wondered if we could use the same trick in test-lib.sh, but it does color some output even on success. But on further thought, the reason that I couldn't measure any impact of tput in my other message may have just been because I was running under "prove". So there's no tty and thus no coloring in the first place. Not to mention that I am using --verbose-log, which also suppresses color.

So I suspect there is really nothing to speed up at all. Most cases running all of the tests will end up turning off color anyway. And if they are not, they are probably bottle-necked on the terminal speed. ;)

-Peff
Previous: Eric SunshineNext: Jeff King
Message 9 of 18 in “chainlint: colorize problem annotations and test delimiters”
  1. chainlint: colorize problem annotations and test delimitersEric Sunshine via GitGitGadget, Sep 12, 2022
  2. Junio C HamanoSep 12, 2022
  3. Eric SunshineSep 13, 2022
  4. Junio C HamanoSep 13, 2022
  5. Eric SunshineSep 13, 2022
  6. Jeff KingSep 13, 2022
  7. Jeff KingSep 13, 2022
  8. Eric SunshineSep 13, 2022
  9. Jeff KingSep 13, 2022
  10. Jeff KingSep 13, 2022
  11. chainlint: colorize problem annotations and test delimitersEric Sunshine via GitGitGadget, Sep 13, 2022
  12. Jeff KingSep 13, 2022
  13. Junio C HamanoSep 13, 2022
  14. Ævar Arnfjörð BjarmasonOct 24, 2022
  15. chainlint.pl's new "deparse" output (was: [PATCH v2] [...])Ævar Arnfjörð Bjarmason, Oct 24, 2022
  16. Eric SunshineOct 25, 2022
  17. Eric SunshineOct 25, 2022
  18. Ævar Arnfjörð BjarmasonOct 25, 2022

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.