From 252ac589969acbc4c17379a4e862a18e1518d12d Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Sat, 29 Jan 2022 14:14:17 -0700 Subject: patman: Rename Color() method to build() This method has the same name as its class which is confusing. It is also annoying when searching the code. It builds a string with a colour, so rename it to build(). Signed-off-by: Simon Glass --- tools/patman/tout.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tools/patman/tout.py') diff --git a/tools/patman/tout.py b/tools/patman/tout.py index 7eb555aaaea..ff0fd92afcc 100644 --- a/tools/patman/tout.py +++ b/tools/patman/tout.py @@ -64,7 +64,7 @@ def progress(msg, warning=False, trailer='...'): _progress = msg + trailer if stdout_is_tty: col = _color.YELLOW if warning else _color.GREEN - _stdout.write('\r' + _color.Color(col, _progress)) + _stdout.write('\r' + _color.build(col, _progress)) _stdout.flush() in_progress = True else: @@ -82,7 +82,7 @@ def _output(level, msg, color=None): if verbose >= level: clear_progress() if color: - msg = _color.Color(color, msg) + msg = _color.build(color, msg) if level < NOTICE: print(msg, file=sys.stderr) else: -- cgit v1.2.3