call app.setup first
This commit is contained in:
parent
04ae6a8851
commit
4979d598f1
|
@ -31,6 +31,9 @@ def cli(ctx, config):
|
||||||
global app
|
global app
|
||||||
app = Application(config)
|
app = Application(config)
|
||||||
|
|
||||||
|
if ctx.invoked_subcommand != 'convert':
|
||||||
|
app.setup()
|
||||||
|
|
||||||
if not ctx.invoked_subcommand:
|
if not ctx.invoked_subcommand:
|
||||||
if app.config.host.endswith('example.com'):
|
if app.config.host.endswith('example.com'):
|
||||||
cli_setup.callback()
|
cli_setup.callback()
|
||||||
|
@ -38,9 +41,6 @@ def cli(ctx, config):
|
||||||
else:
|
else:
|
||||||
cli_run.callback()
|
cli_run.callback()
|
||||||
|
|
||||||
if ctx.invoked_subcommand != 'convert':
|
|
||||||
app.setup()
|
|
||||||
|
|
||||||
|
|
||||||
@cli.command('convert')
|
@cli.command('convert')
|
||||||
@click.option('--old-config', '-o', help='path to the old relay config')
|
@click.option('--old-config', '-o', help='path to the old relay config')
|
||||||
|
|
Loading…
Reference in a new issue