From 134cd01b16cd5077366de9286415fa7db54391ba Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 12 Oct 2026 11:17:56 +0000 Subject: [PATCH 01/11] fix(cli): kits load under plain node, dev reloads local helpers, import hints Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01BG6n8mwoFq1jmay9zCPS6n --- docs/cli.md | 13 +-- registry/dist/items/inbox-triage.json | 12 +-- registry/inbox-triage/approve.ts | 2 +- registry/inbox-triage/channels/inbound.ts | 2 +- registry/inbox-triage/hooks.ts | 2 +- registry/inbox-triage/memory/senders.ts | 2 +- registry/inbox-triage/tools/inbox.ts | 2 +- registry/inbox-triage/tools/replies.ts | 2 +- src/agentDir/importModule.test.ts | 55 ++++++++++++ src/agentDir/importModule.ts | 105 ++++++++++++++++++++-- src/agentDir/loadAgentDir.test.ts | 31 +++++++ src/cli/defaultRegistry.test.ts | 28 ++++++ 12 files changed, 233 insertions(+), 23 deletions(-) create mode 100644 src/agentDir/importModule.test.ts diff --git a/docs/cli.md b/docs/cli.md index e0f80afb8..0eb458d1a 100644 --- a/docs/cli.md +++ b/docs/cli.md @@ -30,7 +30,7 @@ lousho dev [--port N] [--host H] [--all lousho chat [--model provider/model] [--session id] [--store sqlite:] [--traces[=dir]] lousho acp [--model provider/model] lousho add [--registry ] [--dir ] [--yes] [--allow ] [--overwrite] [--dry-run] (or --list) -lousho build --target= [--out=] (or --agent=) +lousho build --target= [--out=] (or --agent=) lousho studio [--port N] [--host H] [--prod|--dev] lousho mcp [--http --port N --host H] lousho doctor [agent.yaml|json|agent-dir] [--json] [--ping] @@ -41,8 +41,8 @@ lousho --version Every command parses its flags the same way (Node's `parseArgs`, strict): `--flag value` and `--flag=value` both work, the last of a repeated flag wins -(`--tag` accumulates), `--` ends the flags, and `-h` / `--help` prints the -command's usage and exits 0. An unknown flag, a flag without its value (it +(`--tag` accumulates), `--` ends the flags, and `-h` / `--help` (or `lousho help +`) prints the command's usage and flags and exits 0. An unknown flag, a flag without its value (it never takes the next flag as its value) or an extra argument fails with `LOUSHO_CONFIG_INVALID` and the usage line. A value that starts with `-` needs the `=` form: `--model=-x`. `--traces` is the one flag whose value is optional: @@ -147,8 +147,10 @@ without restarting the server or dropping the port: `require` specifiers, found once at startup; no bundler). Directory and module files are imported with a `?t=