Skip to content
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

feat: support NO_COLOR by updating kleur #108

Merged
merged 1 commit into from
Dec 1, 2021

Conversation

Venefilyn
Copy link

@Venefilyn Venefilyn commented May 10, 2021

Some terminals do not support colors and will output a bunch of
unnecessary clutter instead. kleur as of v4.1.0 support NO_COLOR
var which disables color completely

@lukeed
Copy link
Owner

lukeed commented May 10, 2021

This is already possible via NO_COLOR environment variable, which is far more standardized. And some of these terminals set that ENV automatically

@Venefilyn
Copy link
Author

Venefilyn commented May 10, 2021

Ah interesting, didn't know about that. Though it doesn't work

Got an npm start script with

sirv dist --cors --etag --single --host --port 8080

and running it with the NO_COLOR doesn't change anything. Still outputs color

$ NO_COLOR=true npm start

@Venefilyn
Copy link
Author

Venefilyn commented May 10, 2021

@lukeed Ah, kleur was outdated. Updated it to the latest version in the latest commit and changed the PR. From what I understand changing it from v3 to v4 shouldn't affect this repo

@Venefilyn Venefilyn changed the title feat: add --no-color feat: support NO_COLOR by updating kleur May 10, 2021
@Venefilyn
Copy link
Author

Hi @lukeed, wondering if you have time to look at this soon

@lukeed
Copy link
Owner

lukeed commented Jun 15, 2021

Hey, thanks. This is actually a breaking change because of the exports map within kleur@4.x
I'll merge this after the next round of changes for sirv too, which will also include other breaking changes

@lukeed lukeed changed the base branch from master to next December 1, 2021 08:16
@lukeed lukeed merged commit 72292ff into lukeed:next Dec 1, 2021
lukeed pushed a commit that referenced this pull request Dec 29, 2021
@Venefilyn Venefilyn deleted the feat/no-color branch January 8, 2022 13:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants