Add --log-level command line argument

Support changing the log level to the desired value easily.
For example, this is useful to suppress progress messages but
keep logging warnings and errors.
This commit is contained in:
Enrico Tröger
2022-05-26 10:04:36 +02:00
parent 63441ebfbc
commit 3d5eb359e2
3 changed files with 22 additions and 9 deletions

View File

@@ -162,6 +162,11 @@ def parse_args(args=None):
default='.',
dest='output_directory',
help='directory at which to backup the repositories')
parser.add_argument('-l',
'--log-level',
default='info',
dest='log_level',
help='log level to use (default: info, possible levels: debug, info, warning, error, critical)')
parser.add_argument('-i',
'--incremental',
action='store_true',