Prefer flask run --debug in docs

This commit is contained in:
Grey Li 2022-08-23 12:44:50 +08:00 committed by David Lord
parent 4bc0e4943d
commit bd26928fdb
No known key found for this signature in database
GPG key ID: 7A1C87E3F5BC42A8
9 changed files with 15 additions and 19 deletions

View file

@ -837,11 +837,6 @@ class SeparatedPathType(click.Path):
expose_value=False,
help="The key file to use when specifying a certificate.",
)
@click.option(
"--debug/--no-debug",
default=None,
help="Enable or disable the debug mode.",
)
@click.option(
"--reload/--no-reload",
default=None,
@ -883,7 +878,6 @@ def run_command(
info,
host,
port,
debug,
reload,
debugger,
with_threads,
@ -916,8 +910,7 @@ def run_command(
# command fails.
raise e from None
if debug is None:
debug = get_debug_flag()
debug = get_debug_flag()
if reload is None:
reload = debug
@ -940,6 +933,9 @@ def run_command(
)
run_command.params.insert(0, _debug_option)
@click.command("shell", short_help="Run a shell in the app context.")
@with_appcontext
def shell_command() -> None: