new package build

This commit is contained in:
Nick Sweeting 2020-10-31 03:08:41 -04:00
parent 18355dc2c6
commit 79051ca15b
5 changed files with 146 additions and 113 deletions

View file

@ -22,6 +22,7 @@ from .config import (
ANSI,
IS_TTY,
TERM_WIDTH,
SHOW_PROGRESS,
SOURCES_DIR_NAME,
stderr,
)
@ -82,7 +83,6 @@ class TimedProgress:
"""Show a progress bar and measure elapsed time until .end() is called"""
def __init__(self, seconds, prefix=''):
from .config import SHOW_PROGRESS
self.SHOW_PROGRESS = SHOW_PROGRESS
if self.SHOW_PROGRESS:
self.p = Process(target=progress_bar, args=(seconds, prefix))
@ -461,6 +461,9 @@ def printable_folders(folders: Dict[str, Optional["Link"]],
html: bool=False,
csv: Optional[str]=None,
with_headers: bool=False) -> str:
from .index.json import MAIN_INDEX_HEADER
links = folders.values()
if json:
from .index.json import to_json

View file

@ -225,11 +225,14 @@ def version(quiet: bool=False,
for name, folder in EXTERNAL_LOCATIONS.items():
print(printable_folder_status(name, folder))
print()
if DATA_LOCATIONS['OUTPUT_DIR']['is_valid']:
print()
print('{white}[i] Data locations:{reset}'.format(**ANSI))
for name, folder in DATA_LOCATIONS.items():
print(printable_folder_status(name, folder))
else:
print()
print('{white}[i] Data locations:{reset}'.format(**ANSI))
print()
check_dependencies()