Skip to content
Snippets Groups Projects
Commit a6c38ebd authored by Yoann Schneider's avatar Yoann Schneider :tennis:
Browse files

Align at right, except first column

parent 6e610e37
No related branches found
No related tags found
1 merge request!50Align at right, except first column
Pipeline #168143 passed
......@@ -6,6 +6,10 @@ def print_markdown_table(header: list[str], rows: list[list]) -> None:
table = PrettyTable()
table.field_names = header
table.set_style(MARKDOWN)
# Align all columns at right
table.align = "r"
# First column should be left aligned still
table.align[header[0]] = "l"
table.add_rows(rows)
print(table)
......
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