mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2025-05-24 19:54:25 -04:00
show human readable filesize in version info
This commit is contained in:
parent
b0ace38273
commit
168d253c17
1 changed files with 3 additions and 3 deletions
|
@ -9,7 +9,7 @@ import re
|
|||
import sys
|
||||
import argparse
|
||||
|
||||
from ..legacy.util import reject_stdin
|
||||
from ..legacy.util import reject_stdin, human_readable_size
|
||||
from ..legacy.config import (
|
||||
ANSI,
|
||||
VERSION,
|
||||
|
@ -80,10 +80,10 @@ def print_folder_status(name, folder):
|
|||
num_files = (
|
||||
f'{len(os.listdir(folder["path"]))} files'
|
||||
if os.path.isdir(folder['path']) else
|
||||
'exists'
|
||||
human_readable_size(os.path.getsize(folder['path']))
|
||||
)
|
||||
else:
|
||||
num_files = '?'
|
||||
num_files = 'missing'
|
||||
|
||||
print(
|
||||
ANSI[color],
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue