feat: make chat the default command

Running 'webber-cli' without arguments now starts chat mode.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-01-14 13:09:39 +01:00
co-authored by Claude Opus 4.5
parent b87e61248e
commit 9be877e9a0
+13 -3
View File
@@ -99,7 +99,8 @@ def create_prompt_session(working_dir: str) -> PromptSession:
app = typer.Typer(
name="webber-cli",
help="CLI client for the Webber API",
no_args_is_help=True,
no_args_is_help=False,
invoke_without_command=True,
add_completion=False,
)
@@ -141,8 +142,9 @@ def _confirm_auto_accept() -> bool:
)
@app.callback()
@app.callback(invoke_without_command=True)
def main(
ctx: typer.Context,
version: bool = typer.Option(
False,
"--version",
@@ -153,7 +155,15 @@ def main(
),
) -> None:
"""Webber CLI - Talk to the Webber API."""
pass
# Default to chat command if no subcommand given
if ctx.invoked_subcommand is None:
chat(
directory=".",
api_url=None,
mode=None,
resume=None,
stream=None,
)
@app.command()