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

Re: [PATCH] help: colorize man pages

From
Felipe Contreras <felipe.contreras@gmail.com>
Date
May 21, 2021, 18:09 UTC
Message-ID
<60a7f7427eab6_55039208ba@natae.notmuch>
In-Reply-To
<YKcFrbuuJrWAxXgm@camp.crustytoothpaste.net>
brian m. carlson wrote:
Show 11 quoted lines
> On 2021-05-19 at 08:41:44, Ævar Arnfjörð Bjarmason wrote:
> > It also doesn't seem to me to satisfy their FAQ point #1, i.e. users who
> > actually want no color at all can just set TERM=dumb, and we support
> > that. The proposed patch is the same as having TERM=dumb set.
> > 
> > This NO_COLOR=1 actually means something like "I do support colors, so
> > show them if it's important, but don't color things willy-nilly".
> 
> I don't agree.  The way I read it is that it means that if your program
> receives colored input, it is not obligated to strip it out, but it is
> obligated not to add any.
The very example they give says otherwise:
  It is reasonable to configure certain software such as a text editor
  to use color
They are saying a text editor adding color is *fine*.
> NO_COLOR=1 says, "I don't want color, but I have a fully functional
> terminal I would like to use, thank you."
That's not what it says.
> In other words, I think in this case, the user has opted to configure
> their editor as they like it and invoke it without NO_COLOR, but has
> instructed other programs to not add color with NO_COLOR.

That is a reasonable interpretation... until you read the next answer:

  A user should be able to export $NO_COLOR in their shell configuration
  file as a default, but configure a specific program in its
  configuration file to specifically enable color.

The whole point is not to configure each program to disable color, but have a global NO_COLOR.

So I don't think your interpretation is correct.
-- 
Felipe Contreras
Previous: brian m. carlsonNext: Igor Djordjevic
Message 11 of 33 in “help: colorize man pages”
  1. help: colorize man pagesFelipe Contreras, May 18, 2021
  2. brian m. carlsonMay 18, 2021
  3. Felipe ContrerasMay 18, 2021
  4. brian m. carlsonMay 18, 2021
  5. Junio C HamanoMay 19, 2021
  6. brian m. carlsonMay 19, 2021
  7. Junio C HamanoMay 19, 2021
  8. Ævar Arnfjörð BjarmasonMay 19, 2021
  9. Felipe ContrerasMay 19, 2021
  10. brian m. carlsonMay 21, 2021
  11. Felipe ContrerasMay 21, 2021
  12. Igor DjordjevicMay 21, 2021
  13. Felipe ContrerasMay 21, 2021
  14. Igor DjordjevicMay 21, 2021
  15. Felipe ContrerasMay 21, 2021
  16. Igor DjordjevicMay 22, 2021
  17. Felipe ContrerasMay 22, 2021
  18. Igor DjordjevicMay 23, 2021
  19. Felipe ContrerasMay 23, 2021
  20. Igor DjordjevicMay 21, 2021
  21. Junio C HamanoMay 21, 2021
  22. Ævar Arnfjörð BjarmasonMay 19, 2021
  23. Jeff KingMay 19, 2021
  24. Felipe ContrerasMay 19, 2021
  25. Felipe ContrerasMay 19, 2021
  26. Felipe ContrerasMay 19, 2021
  27. brian m. carlsonMay 20, 2021
  28. Junio C HamanoMay 20, 2021
  29. Felipe ContrerasMay 20, 2021
  30. Junio C HamanoMay 20, 2021
  31. Felipe ContrerasMay 20, 2021
  32. Felipe ContrerasMay 20, 2021
  33. Felipe ContrerasMay 19, 2021

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.