2
0
mirror of https://github.com/frappe/bench.git synced 2024-11-13 16:56:33 +00:00

fix: Set verbosity if --verbose is passed anywhere period

Fixes https://github.com/frappe/bench/issues/1224
This commit is contained in:
Gavin D'souza 2021-12-28 12:42:53 +05:30
parent 9802feaa9c
commit 2caf7e7d15

View File

@ -40,7 +40,7 @@ src = os.path.dirname(__file__)
def cli():
global from_command_line, bench_config, is_envvar_warn_set
global from_command_line, bench_config, is_envvar_warn_set, verbose
from_command_line = True
command = " ".join(sys.argv)
@ -48,6 +48,9 @@ def cli():
is_envvar_warn_set = not (os.environ.get("BENCH_DEVELOPER") or os.environ.get("CI"))
is_cli_command = len(sys.argv) > 1 and not argv.intersection({"src", "--version"})
if "--verbose" in sys.argv:
verbose = True
change_working_directory()
logger = setup_logging()
logger.info(command)