Skip to content

Commit

Permalink
I've cut too much
Browse files Browse the repository at this point in the history
  • Loading branch information
Chiara Rasi committed Feb 5, 2024
1 parent c263195 commit e70c421
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
Empty file added schug/cli/__init__.py
Empty file.
20 changes: 20 additions & 0 deletions schug/cli/base.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
import typer
import uvicorn
from schug.config import settings

cli = typer.Typer()


@cli.callback()
def callback():
"""
Welcome to the CLI
"""


@cli.command("serve")
def serve_app(reload: bool = typer.Option(False, "--reload")):
"""Start a dev server for the schug app"""
typer.echo("Serving schug")
app = "schug.main:app"
uvicorn.run(app=app, host=settings.host, port=settings.port, reload=reload)

0 comments on commit e70c421

Please sign in to comment.