feat: integrated with poetry scripts

This commit is contained in:
Xyphuz 2022-05-08 23:03:16 +08:00
parent 3f4c41a883
commit 6adc0abfca
3 changed files with 9 additions and 6 deletions

View file

@ -1,9 +1,5 @@
from compose_viz import cli, __app_name__
def main() -> None:
cli.app(prog_name=__app_name__)
from compose_viz.cli import start_cli
if __name__ == "__main__":
main()
start_cli()

View file

@ -55,3 +55,7 @@ def compose_viz(
typer.echo(f"Successfully parsed {input_path}")
raise typer.Exit()
def start_cli() -> None:
app(prog_name=__app_name__)

View file

@ -15,3 +15,6 @@ pytest = "^7.1.2"
[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"
[tool.poetry.scripts]
compose_viz = "compose_viz.cli:start_cli"