Closed Jayllyz closed 6 months ago
It seems one option(rather than two --color
and --no-color
) is enough for this feature.
I suggest it enabled by default and --no-color
to disable it.
Hello,
It seems that chalk implements --color
and --no-color
automatically, so I could delete what I did in index
except the part where I set color in printOutput
. I don't know how to force the default color since chalk detects itself if the terminal is tty.
What do you suggest?
I also need to update the readme, should I do it here or in another PR?
"Just set color in printOutput
" is acceptable to me.
You can add some descriptions in Readme.md FAQ part, for example:
> Q: How to disable color in output?
Set the environment variable `FORCE_COLOR=0`, See <https://github.com/chalk/chalk?tab=readme-ov-file#supportscolor> for details.
Changes :
Added color output options,
--color
to force colors, or--no-color
to disable them.The Chalk library also uses environment variables such as
FORCE_COLOR
to enable/disable color output.Please let me know if I've made any mistakes, as this is my first contribution to this project.
Preview:
Fixes(if relevant):
Checks
git reset
thengit commit
)npm run build
)npm run lint
to check,npm run fix
to fix)