From 9a6ee71f6fe3c6c7283f3f3ac0be1116fc24449b Mon Sep 17 00:00:00 2001 From: Yanray Wang Date: Mon, 14 Aug 2023 11:30:24 +0800 Subject: [PATCH] code_size_compare: right-align numbers in the comparison result Signed-off-by: Yanray Wang --- scripts/code_size_compare.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/code_size_compare.py b/scripts/code_size_compare.py index 672b80366f..d1e8a1b71b 100755 --- a/scripts/code_size_compare.py +++ b/scripts/code_size_compare.py @@ -604,10 +604,10 @@ class CodeSizeGeneratorWithSize(CodeSizeGenerator): if with_markdown: dash_line = [":----", "----:", "----:", "----:", "----:"] - line_format = "| {0:<30} | {1:<10} | {3:<10} | {2:<12} | {4:<12} |\n" + line_format = "| {0:<30} | {1:>10} | {3:>10} | {2:>12} | {4:>12} |\n" bold_text = lambda x: '**' + str(x) + '**' else: - line_format = "{0:<30} {1:<10} {3:<10} {2:<12} {4:<12}\n" + line_format = "{0:<30} {1:>10} {3:>10} {2:>12} {4:>12}\n" def cal_sect_change( old_size: typing.Optional[CodeSizeGeneratorWithSize.SizeEntry],