Re:New startup sells coffee through SSH
by zzo38computer on Wednesday May 01, 2024 @05:06PM
(#40229414)
Is there an environment variable defined for specifying if you want light or dark colours? If so, then it would help with local programs, and also with remote programs (such as this one) if you add a SendEnv command into the SSH configuration file to specify that SSH should use this environment variable.
[ Parent
| on HN ]
A little non-portable but there is an xterm escape sequence[1] that gets the user's background color: \e]11;?\a
You might also be able to use the reverse-video[2] escape sequence to get something that works depending on the user's color scheme.