feat: select workflow cli target from config
This commit is contained in:
+18
-1
@@ -23,9 +23,26 @@ def root(
|
||||
help="Path to workflow/MCP config JSON.",
|
||||
),
|
||||
] = "wf_mcp.config.json",
|
||||
local: Annotated[
|
||||
bool,
|
||||
typer.Option("--local", help="Force same-process local workflow target."),
|
||||
] = False,
|
||||
url: Annotated[
|
||||
str | None,
|
||||
typer.Option("--url", help="Override workflow JSON-RPC target URL."),
|
||||
] = None,
|
||||
timeout: Annotated[
|
||||
float | None,
|
||||
typer.Option("--timeout", min=0.1, help="Override RPC timeout seconds."),
|
||||
] = None,
|
||||
) -> None:
|
||||
"""Run workflow platform commands."""
|
||||
ctx.obj = {"config_path": config}
|
||||
ctx.obj = {
|
||||
"config_path": config,
|
||||
"force_local": local,
|
||||
"rpc_url": url,
|
||||
"rpc_timeout_seconds": timeout,
|
||||
}
|
||||
|
||||
|
||||
app.add_typer(caps.app, name="cap")
|
||||
|
||||
Reference in New Issue
Block a user