From 6da948c3ce77afb0933a0958c43fed9428bcad15 Mon Sep 17 00:00:00 2001 From: Egor Tensin Date: Sat, 8 May 2021 02:42:27 +0300 Subject: project.toolset: tweak --help-toolsets output --- project/toolset.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/project/toolset.py b/project/toolset.py index a73a8d5..5c5c414 100644 --- a/project/toolset.py +++ b/project/toolset.py @@ -150,7 +150,7 @@ class ToolsetType(Enum): def help(self): if self is ToolsetType.AUTO: - return "Most commonly means 'gcc' on Linux and 'msvc' on Windows." + return "Means 'gcc' on Linux and 'msvc' on Windows." if self is ToolsetType.MSVC: return 'Use cl.exe.' if self is ToolsetType.VISUAL_STUDIO: @@ -237,9 +237,12 @@ class ToolsetVersion: ''' max_name = max((len(str(hint)) for hint in ToolsetType.all())) + max_help = max((len(hint.help()) for hint in ToolsetType.all())) for hint in ToolsetType.all(): + help = hint.help() name_padding = ' ' * (max_name - len(str(hint))) - s += f'| {hint}{name_padding} | {hint.help()}\n' + help_padding = ' ' * (max_help - len(str(help))) + s += f'| {hint}{name_padding} | {hint.help()}{help_padding} |\n' return s @staticmethod -- cgit v1.2.3