wrap scene switch annotations with Annotated

This commit is contained in:
onyx-and-iris 2025-06-04 16:26:27 +01:00
parent 59f52417cd
commit 657fa84ea3

View File

@ -20,7 +20,7 @@ def main():
@app.command('list | ls') @app.command('list | ls')
def list(ctx: typer.Context): def list_(ctx: typer.Context):
"""List all scenes.""" """List all scenes."""
resp = ctx.obj.get_scene_list() resp = ctx.obj.get_scene_list()
scenes = ( scenes = (
@ -64,7 +64,7 @@ def current(
@app.command('switch | set') @app.command('switch | set')
def switch( def switch(
ctx: typer.Context, ctx: typer.Context,
scene_name: str, scene_name: Annotated[str, typer.Argument(help='Name of the scene to switch to')],
preview: Annotated[ preview: Annotated[
bool, bool,
typer.Option(help='Switch to the preview scene instead of the program scene'), typer.Option(help='Switch to the preview scene instead of the program scene'),