diff options
Diffstat (limited to 'pym/portage/output.py')
-rw-r--r-- | pym/portage/output.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/pym/portage/output.py b/pym/portage/output.py index ee792280a..4c533c427 100644 --- a/pym/portage/output.py +++ b/pym/portage/output.py @@ -150,7 +150,13 @@ def _parse_color_map(onerror=None): @rtype: dict @return: a dictionary mapping color classes to color codes """ - myfile = COLOR_MAP_FILE + # FIXME: use config_root iso / (breaks Prefix) + # We can use ObjectProxy to implement lazy initialization of + # codes and _styles, and add an init(config_root="/") function + # that can be called in order adjust the location that color.map + # is read from. + global codes, _styles + myfile = os.path.join('/', COLOR_MAP_FILE) ansi_code_pattern = re.compile("^[0-9;]*m$") quotes = '\'"' def strip_quotes(token): |