fix: use rattail function to create top-level command
share code in case logic ever changes
This commit is contained in:
parent
10e79be01a
commit
cbb5174ac8
|
@ -11,7 +11,7 @@ import shutil
|
||||||
import typer
|
import typer
|
||||||
from typing_extensions import Annotated
|
from typing_extensions import Annotated
|
||||||
|
|
||||||
from rattail.commands.typer import (typer_callback, typer_get_runas_user,
|
from rattail.commands.typer import (make_typer, typer_get_runas_user,
|
||||||
importer_command, file_exporter_command)
|
importer_command, file_exporter_command)
|
||||||
from rattail.commands.importing import ImportCommandHandler
|
from rattail.commands.importing import ImportCommandHandler
|
||||||
from rattail.commands.purging import run_purge
|
from rattail.commands.purging import run_purge
|
||||||
|
@ -19,9 +19,9 @@ from rattail.commands.purging import run_purge
|
||||||
|
|
||||||
log = logging.getLogger(__name__)
|
log = logging.getLogger(__name__)
|
||||||
|
|
||||||
# nb. this is the top-level command for titeship
|
# nb. this is the top-level command
|
||||||
rattail_demo_typer = typer.Typer(
|
rattail_demo_typer = make_typer(
|
||||||
callback=typer_callback,
|
name='rattail_demo',
|
||||||
help="Rattail Demo (custom Rattail system)"
|
help="Rattail Demo (custom Rattail system)"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue