Skip to content
Snippets Groups Projects
Commit 1d833368 authored by Andreas Klöckner's avatar Andreas Klöckner
Browse files

Only enable terminal colors if colorama is available

parent 8008719b
No related branches found
No related tags found
No related merge requests found
......@@ -137,10 +137,18 @@ class Options(Record):
write_wrapper=False, highlight_wrapper=False,
write_cl=False, highlight_cl=False,
edit_cl=False, cl_build_options=[],
allow_terminal_colors=True,
allow_terminal_colors=None,
disable_global_barriers=False,
):
if allow_terminal_colors is None:
try:
import colorama # noqa
except ImportError:
allow_terminal_colors = False
else:
allow_terminal_colors = True
Record.__init__(
self,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment