IPython does a decent job of providing console output in color on all the platforms I use it on. If you’re like me and you’ve wanted to use its coloring functionality for your own terminal output, here’s a snippet that should get you started.
[python]
from IPython import ColorANSI
from IPython.genutils import Term
tc = ColorANSI.TermColors()
red = tc.Red + "Red" + tc.Normal
print >> Term.cout, red
blue = tc.Blue + "Blue" + tc.Normal
print >> Term.cout, blue
[/python]
Assuming you have color output enabled (if you’re on Windows, you’ll need PyReadline), you should be able to %paste the plain text from the snippet above into IPython and see the output below.
Red
Blue