jorgebucaran / colorette

🌈Easily set your terminal text color & styles
MIT License
1.61k stars 51 forks source link

Wrong support detection on Windows #90

Closed MartinKolarik closed 2 years ago

MartinKolarik commented 2 years ago

This check assumes that anything running on Windows supports colors, which is not true and results in garbage output sometimes. For example, the GitHub Desktop app doesn't support colors for its output for precommit hooks and it sets env.TERM to dumb. Comparing with supports-color package which handles this correctly, this check should probably have a higher priority than the platform.

jorgebucaran commented 2 years ago

Could you submit a patch or show us in our code what we'd need to do to support your use-case on Windows? Thanks.

MartinKolarik commented 2 years ago

Sure, I'll send a PR.