rename to match PyPI project name

This commit is contained in:
2024-04-27 18:43:08 +01:00
parent 915adcf054
commit 732bee7b4f
11 changed files with 12 additions and 12 deletions

22
ipilot/print_table.py Normal file
View File

@ -0,0 +1,22 @@
#!/usr/bin/env python3
"""MODULE: Provides functions for preparing, then printing, retrieved data."""
from tabulate import tabulate
def generate_prefix_string(prefixes: list) -> str | None:
"""Generate a string that spilts prefixes into rows of 4."""
num_per_row = 4
try:
ret: str = ""
for i in range(0, len(prefixes), num_per_row):
ret += ", ".join(prefixes[i : i + num_per_row]) + "\n"
return ret
except AttributeError:
return None
def print_table(table_data) -> None: # pragma: no cover
"""Print table generated by tabulate."""
print(tabulate(table_data))