git-svn-id: https://svn.osgeo.org/grass/grass/trunk@67001 15284696-431f-4ddb-bdfa-cd5b030d7da7
@@ -143,7 +143,10 @@ def colorize(text, attrs=None, pattern=None):
if COLORIZE:
- from termcolor import colored
+ try:
+ from termcolor import colored
+ except ImportError:
+ grass.fatal(_("Cannot colorize, python-termcolor is not installed"))
else:
def colored(pattern, attrs):
return pattern