Coder Social home page Coder Social logo

Comments (5)

hykilpikonna avatar hykilpikonna commented on August 15, 2024

hmm weird, git bash should be using mintty internally if I remember correctly, IDK why it is doing that.

Also, the color escape sequences used in the config screen should be the same with the actual rendering screen, just that the actual rendering is printed by bash while the config screen is printed by python... it might be some implicit conversion that git bash is doing.

Can you try running if each of these can print colors in git bash?

python3 -c "print('\033[1;33mTest Colors\033[0m;')"
bash -c "printf '\033[1;33mTest Colors\033[0m;'"

from hyfetch.

Kwonunn avatar Kwonunn commented on August 15, 2024

image
image

To me this seems like Python might be outputting 'raw' strings or something

from hyfetch.

hykilpikonna avatar hykilpikonna commented on August 15, 2024

Both work totally fine on Unix.

image

Since Windows' terminal emulator doesn't natively support Xterm color escape sequences but have its own set of color interface, I would guess that git bash is probably doing some implicit conversion, and since windows Python isn't doing the conversion, python output isn't colored on Windows.

I have no idea of how to work around this since I'm not familiar with how Windows cmd's color coding works... maybe we can try colorama's conversion?

pip install colorama
python3 -c "import colorama; colorama.just_fix_windows_console(); print('\033[1;33mTest Colors\033[0m;')"

from hyfetch.

R3AP3 avatar R3AP3 commented on August 15, 2024

this may be an issue with msys/mingw64... i had this problem with multicolor support for my msys shell on windows too and fixxed it by literally making pacman -Syu and that fixxed it.

randomly found this issue and it remembered me of that issue i had. This is not an issue with hyfetch mostlikely (even tho i never used it until now)

from hyfetch.

Kwonunn avatar Kwonunn commented on August 15, 2024

image
Colorama does work, so using that seems like a good fix

from hyfetch.

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.