-
Notifications
You must be signed in to change notification settings - Fork 410
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
🚀 show an error when specifying true-color in 256-color mode #1429
Comments
I want to second this. Was trying out a colorscheme for delta, but I got a totally different look even though everything seemed to be set up correctly. I found this out because Took me a lot of time debugging this so having some error / warning would be highly appreciated. My solution was to add |
I think the default can become true-color / 24bit, with an option to still auto-detect or disable this entirely. Nearly all terminal emulators support it, see https://github.com/termstandard/colors. @bash, as you have been looking at a lot of terminals recently, what do you think? The url above also mentions a way to querying a terminal, that may be a bonus feature for terminal-colorosorus. |
I haven't looked at true-color support in particular so I unfortunately don't have much to add on that front. The list of terminals in https://github.com/termstandard/colors looks pretty complete to me though (compared to my color detection survey). Probably the most important offender in the "not supported" pile is macOS's default Terminal.app, so I'm not sure how great it'd be to enable true-color by default 1. Adding a warning if a theme uses true-color but the terminal doesn't support it might also be a start as @lugen4ro suggested—but maybe too noisy? For reference this is how bat reports warnings. Regarding detection: TIL that such a query exists—looks really interesting. I'm generally open to adding something like this to terminal-colorsaurus but there are a few notes that I'd want to consider:
sigh—of course Footnotes
|
I set
plus-style = "syntax #114433"
in my.gitconfig
and it worked on my system. I ssh-ed into a container (running an sshd, unusual, yes) using the same config and it output a completely different colorit took me a while of debugging to realize it was outputting in color space 5 (256-color,
\33[48;5;237
) instead of color space 2 (true-color,\33[48;2;17;68;51
)I came to file a bug report with a pile of screenshots but found #111 which mentioned
--24-bit-color
(now--true-color
) andCOLORTERM
.there's definitely something broken in my container environment sinceit would have saved me a bunch of time if delta had just noted my choice of true/24-bit color and refused to continue instead of picking a 256-colorCOLORTERM
isn't set, butEDIT: turns out
COLORTERM
just isn't forwarded over ssh and my terminal's terminfo isn't in the most common distribution (ncurses) due to a... disagreement between the maintainers kovidgoyal/kitty#879 (comment)another option that might be nice is to default
true-color
to always (cronvel/terminal-kit#139 (comment)) since almost every terminal supports it nowadays, especially the ones thatdelta
is likely to run onThe text was updated successfully, but these errors were encountered: