01mf02 / jaq

A jq clone focussed on correctness, speed, and simplicity
MIT License
2.61k stars 63 forks source link

Feature request: NO_COLOR standard implementation #189

Closed hellishvictor closed 2 weeks ago

hellishvictor commented 2 weeks ago

Hi, it would be great implement the NO_COLOR standard on jaq since there's many CLI already with it and save the users from use "color=never", "--monochrome-color" or whatever.

Command-line software which adds ANSI color to its output by default should check
 for a NO_COLOR environment variable that, when present and not an empty string
 (regardless of its value), prevents the addition of ANSI color.

By adopting this standard, users that prefer to have plain, non-colored text output
 can export NO_COLOR=1 to their shell’s environment and automatically disable color
 by default in all supported software.

If your software outputs color by default, please consider not doing so. 

More info on: https://no-color.org/

Btw, I love jaq. Cheers

01mf02 commented 2 weeks ago

Done. Thanks for your nice comment. :)