4378 shaares
Disclaimer: this post was heaviliy inspired by the 2 following gists:
color_log.py
usingtermcolor
recipescolorlog.py
usingcolorama
I loved the simplicity of the first, not having to manipulate any of the logging internal API, but I prefer colorama
over termcolor
.
Without further ado, there is my solution …