Code Monkey home page Code Monkey logo

Comments (7)

sam-mcbr avatar sam-mcbr commented on July 22, 2024 1

@gjtorikian Apologies for the long delay, I was able to confirm that this change enables colored output!

from html-proofer.

gjtorikian avatar gjtorikian commented on July 22, 2024 1

No worries, glad it worked, I'll send this out as 5.0.9 soon.

from html-proofer.

gjtorikian avatar gjtorikian commented on July 22, 2024

Can you try setting the environment variable CLICOLOR_FORCE = '1' ?

from html-proofer.

sam-mcbr avatar sam-mcbr commented on July 22, 2024

Thanks for the quick response! Unfortunately still showing uncolored text

from html-proofer.

gjtorikian avatar gjtorikian commented on July 22, 2024

Would it be possible to see how you're setting that env var, or a sample workflow?

Terminal color output is dependent on https://github.com/ku1ik/rainbow/blob/138bc054cd196b54ed6a935c52653a8ac3761dfc/lib/rainbow.rb#L10-L12

html-proofer isn't doing any TTY determination, so I'm surprised the underlying library's mechanism isn't working.

from html-proofer.

sam-mcbr avatar sam-mcbr commented on July 22, 2024

Sorry for the delay, yeah I can share an example of how I was setting the var soon. But the reason I thought the TTY would affect this is I saw this line where Rainbow is only invoked if stdout is a TTY:

if (STDOUT_LEVELS.include?(level) && $stdout.isatty) ||

Could this be the cause of no color even with the env var set?

from html-proofer.

gjtorikian avatar gjtorikian commented on July 22, 2024

I guess Rainbow updated its logic at some point, because I see now that it handles TTY/color enabling on its own.

Could you try the branch at #818 and see if that works for you?

from html-proofer.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.