crayons
crayons copied to clipboard
embedded colored strings unset outer colored string
Situations like this (or here in pipenv):
print(crayons.blue('horses, like {0}, eat grass too'.format(crayons.red('goats'))))
produce the following in Python 3.6.2:
To me, the expectation is that embedded colored text would not effect the coloring outside of there, so you'd get the following instead:
I spotted this after spawning a virtualenv shell from pipenv :) Notice closing parenthesis:
Can this fix also be issued for fstrings?
So it's possible to do something like this
crayons.green(f'should be green {crayons.blue("should be blue")} should be green ')
@kennethreitz Don't you like this repo anymore? :disappointed:
Just use RichConsole.py