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 20, 2021, 02:45 UTC
Message-ID
<60a5cd3ed5aaf_1e275208a0@natae.notmuch>
In-Reply-To
<YKXBdQ36MYz2YG8s@camp.crustytoothpaste.net>
brian m. carlson wrote:
Show 14 quoted lines
> On 2021-05-19 at 09:26:12, Ævar Arnfjörð Bjarmason wrote:
> > 
> > On Tue, May 18 2021, brian m. carlson wrote:
> > 
> > > Would you consider various projects coloring their respective manual
> > > pages differently to be a desirable state of affairs?
> > 
> > I think it's an important distinction that we're not coloring any manual
> > pages, it's a question of whether we invoke "man" invoked by "git help
> > <whatever>" with the exact same paramaters/options a user would get with
> > "man git-<whatever>".
> 
> Yes.  I would expect that if the man option is chosen, then we invoke
> man without modification.
Do you also expect git to call diff without options?
> The documentation says, "use the man program as usual".  "As usual"
> implies the way the user would invoke it.
The documentation can be updated.
> > I don't think it's confusing in that context if we learn to do some "man
> > with fancy on top" in this mode.
> It's pretty obvious that "git help commit" and "cargo help build" both
> are intended to invoke man when used in the normal way.
And I don't.
I expect the output `foo help $x` to be decided by foo.
If I do `python help len` and I get an error, that's fine.
Show 7 quoted lines
> > But if colors only add, but don't substract information by default
> > that's not an issue for the color blind, correct? Or at least that's
> > been my understanding in helping color blind user in the past (and not
> > being color blind myself).
> 
> The problem becomes if the color is indistinguishable from other
> elements.

It is not indistiguishable; a blind person would be able to distinguish them. As much as they can without the patch.

> It is _also_ a problem if we have two colors with sufficient contrast
> between the foreground and background but those colors look the same and
> there is no other distinguishing factor.
There is another distinguising factor: they are *bold*, or _underlined_.
> So, yes, if the colors only add information and they can otherwise be
> distinguished, then it's fine.
We are setting *bold*, _underlined_, and REVERSE.
Exactly in the same way as they are set already.
A truly colorblind person would see no difference at all.
> What I don't like is when a program colors text in a certain way, I
> can't read it, and then I can't read the help output or documentation to
> turn it off.

If you can't read `man git`, that has absolutely nothing to do with this patch.

> I am specifically arguing against coloring our documentation
We already already coloring our documentation.
> and help output because it leaves users with little recourse to fix
> the problem.
man git.
-- 
Felipe Contreras
Previous: Felipe ContrerasNext: Felipe Contreras
Message 32 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.