Chalk: Colors in docker container

Created on 13 Aug 2015  路  3Comments  路  Source: chalk/chalk

Hi.
I am using gulp in my docker container (which depends on chalk)
It uses, by default, chalk.red, etc.
It works fine except for the fact, colors don't work in docker container. All logs come out B&W.
The work around for that is usage of chalk.styles.color.open and ... .end syntax.

Is there a way to make all default functions use ansi coloring?

question

Most helpful comment

Try setting the environment variable FORCE_COLOR=1. If that doesn't work (it should), try running the command with --colors as a flag.

You can check out the supports-color source for more things to try :)

All 3 comments

Try setting the environment variable FORCE_COLOR=1. If that doesn't work (it should), try running the command with --colors as a flag.

You can check out the supports-color source for more things to try :)

Hey @Martodox, I'm going to assume this worked for you. If you have any other issues let us know!

FORCE_COLOR=1 worked for me, thanks!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

langpavel picture langpavel  路  8Comments

RichaJha1119 picture RichaJha1119  路  5Comments

roblg picture roblg  路  7Comments

macOneOone picture macOneOone  路  6Comments

HillTravis picture HillTravis  路  8Comments