-
Notifications
You must be signed in to change notification settings - Fork 36
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
Colorize Sphinx output #31
Comments
Can you explain more? Looking at the docs, I see |
Yes. It looks like the docs web page doesn't mention it, but running $ python -m sphinx --help
[...]
--color do emit colored output (default: auto-detect)
-N, --no-color do not emit colored output (default: auto-detect)
[...] |
According to docs, the Unfortunately, that doesn't seem to be the case (see this recent run): There's color in there, but it's implicit color ("warning" text signals red on the line). Based on what I see on my mac, if sphinx color were honored, one should see bold text and purple/green for "index". Since the current configuration is already configured correctly to support color, I'm disinclined to add additional configuration, at least without an upstream report explaining why the existing FORCE_COLOR is insufficient. A redundant config would be cruft. I'm declaring this done and welcome further investigation to determine why FORCE_COLOR is not honored. |
IIRC Sphinx itself honors the environment variable but the underlying library does not. Also, custom extensions may end up not honoring it too.. |
@jaraco also, |
Found that PR I was trying to remember. It seemed to be Though when I dag deeper, it turned out Sphinx only uses it under Windows. |
Some CIs don't expose enough information for tools to decide whether they support ANSI-sequences while it's experimentally proven that they do. TBH most of the existing envs support this. In such cases, we need to explicitly tell the tools to output the color markers.
For Sphinx, this essentially means adding
--color
when invoking it. I think this should be a part of the skeleton.The text was updated successfully, but these errors were encountered: