-
-
Notifications
You must be signed in to change notification settings - Fork 12
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
Missing chalk colors from child process #21
Comments
@bender2k14 it would be really great if you could clone the cli code locally and investigate this issue a bit further. this should be particularly related to this part of the CLI code. |
@bender2k14 p.s. tested on Windows 7 default Command Prompt and the colors are working relatively fine (the color palette seems to be more limited). could you also test on the Command Prompt and see if you do not see any colors? P.S. perhaps this is related to this issue? |
Absolutely. What makes you think that code is related to this bug...what should I be looking for? I don't see anything there to do with color. How can I test my changes? My best guess was to start by executing Line 73 in 030ba14
I just need a bit more direction since this is not my normal programming environment. |
because thats the main utility function running sub-commands and piping their output to the standard output. colors disappearing means some form of transformation happening on the output of those sub-commands while being piped. the way I typically test the CLI is to run it from the root of another codedoc project, testing out its various commands. something like this: node ../codedoc-cli/src/index.js update |
setting Mintty aside, based on what you describe it seems like logs from the main CLI process preserve color while logs from sub-processes don't. perhaps some information is being lost in these two lines? |
Yes, I think you are right. To summarize, these two lines pipe the output of a child process to the output of the parent process, but the colors don't come with. That is exactly issue #381 of chalk. |
Let's keep this issue open to monitor the state of that issue in chalk. |
This is a spin off from issue #17
Quoting #17 (comment)
I am using Windows. I use GitKraken to launch a terminal. It opens Mintty 2.9.6.
There are many colors just above each prompt...
![2020-06-10_22-29-01_123_mintty](https://user-images.githubusercontent.com/34664007/84341926-edeefe00-ab69-11ea-9d0c-a589e30a51d1.png)
...but not for error messages from codedoc.
The text was updated successfully, but these errors were encountered: