Need to print colored block in terminal. I wrote this:
from termcolor import colored
...
print(colored('\u2588\u2588\', '#%s' %(color)))
Where color
is color in hex, seems like termcolor
can't work with hex
Also tried module colored
:
import colored
...
color_t = fg('#'+color)
but Python raises KeyError: '#4e1747'
(random color)
What's wrong?