sqlx icon indicating copy to clipboard operation
sqlx copied to clipboard

sqlx CLI help unreadable in light terminals

Open faultymajority opened this issue 1 month ago • 1 comments

I have found these related issues/pull requests

Couldn't find anything related.

Description

I have a white background in my terminal, and the choice of "white" in https://github.com/launchbadge/sqlx/blob/e8384f2a00173c2b120eea72e99d120557fced8b/sqlx-cli/src/opt.rs#L19 causes sqlx --help to be invisible.

I'm aware I can set NO_COLOR=1 to turn the help styles off, but it would be nice to be able to use help out of the box.

Image

Reproduction steps

Type sqlx --help in a white terminal.

SQLx version

0.8.6

Enabled SQLx features

n/a

Database server and version

n/a

Operating system

Linux

Rust version

n/a

faultymajority avatar Nov 23 '25 21:11 faultymajority

We're not using RGB or true colors, we're using ANSI logical colors. Your terminal theme should not be configuring white to be the same as your background. This is how it looks in my terminal. It's not "great", it should probably be a darker color, but its readable.

Image

We should probably switch to using bright (\e1[m) rather than "white" though. This would fix this for you and make it have better contrast for me.

Image Image

We'd happily accept a PR for this.

mehcode avatar Nov 23 '25 22:11 mehcode