kaijibot 2026.6.27 → 2026.6.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.en.md +6 -6
- package/README.md +7 -7
- package/dist/.buildstamp +1 -1
- package/dist/build-info.json +3 -3
- package/dist/cli-startup-metadata.json +1 -1
- package/dist/{command-registry-4L4jgKui.js → command-registry-DMdu_t1F.js} +1 -1
- package/dist/{command-registry-B0vJK-5E.js → command-registry-DzfcgAoH.js} +5 -5
- package/dist/{completion-cli-DzCq1332.js → completion-cli-BHEov8Bb.js} +2 -2
- package/dist/{completion-cli-CG81Kf7k.js → completion-cli-DSFwqqKQ.js} +1 -1
- package/dist/{doctor-completion-BJNkuBub.js → doctor-completion-CCRmJ8E_.js} +1 -1
- package/dist/entry.js +1 -1
- package/dist/extensions/diffs/.kaijibot-runtime-deps-stamp.json +1 -1
- package/dist/extensions/feishu/.kaijibot-runtime-deps-stamp.json +1 -1
- package/dist/extensions/webhooks/.kaijibot-runtime-deps-stamp.json +1 -1
- package/dist/{gateway-cli-CafK4iub.js → gateway-cli-DiZwD1jt.js} +1 -1
- package/dist/index.js +1 -1
- package/dist/{onboard-DuHruikk.js → onboard-CiaJ_cr1.js} +1 -1
- package/dist/plugin-sdk/.boundary-entry-shims.stamp +1 -1
- package/dist/{program-vOUiLQv8.js → program-B4Lh9HnH.js} +1 -1
- package/dist/{prompt-select-styled-YveI0Wpb.js → prompt-select-styled-CSbxwMaJ.js} +1 -1
- package/dist/{register.android-install-B_k8C7oB.js → register.android-install-BUvcr7Tz.js} +29 -8
- package/dist/{register.maintenance-Q2jaxOMk.js → register.maintenance-CtPWHuwH.js} +1 -1
- package/dist/{register.onboard-Cyhfe3SR.js → register.onboard-DuKKuVdd.js} +1 -1
- package/dist/{register.setup-p_KRC7Dg.js → register.setup-BwhZ8gtj.js} +1 -1
- package/dist/{register.subclis-BHC1hwy_.js → register.subclis-1xMEIUE-.js} +3 -3
- package/dist/{register.subclis-DxsFMf6V.js → register.subclis-CjiauVD0.js} +1 -1
- package/dist/{run-main-D1wBtaY7.js → run-main-ONomAiDX.js} +3 -3
- package/dist/{server-Cx5kTwGl.js → server-C3w72H_f.js} +1 -1
- package/dist/{server.impl-Cj_m71p1.js → server.impl-sokp10QV.js} +1 -1
- package/dist/{setup-DlNbSena.js → setup-BGZo-_Jf.js} +8 -5
- package/dist/{setup.finalize-DVqnXQvY.js → setup.finalize-BdGsks0i.js} +2 -2
- package/dist/{update-cli-cTC9wUvG.js → update-cli-DBKmpmBG.js} +3 -3
- package/package.json +1 -1
package/README.en.md
CHANGED
|
@@ -74,7 +74,7 @@ Step into a pit once. That's enough.
|
|
|
74
74
|
|
|
75
75
|
Not locked into any single provider. Switch between domestic and international at will. `kaijibot onboard` wizard auto-discovers configured API keys.
|
|
76
76
|
|
|
77
|
-
| China
|
|
77
|
+
| China | International | Aggregator / Self-hosted |
|
|
78
78
|
| ---------------------------------------------- | ----------------------------------------------- | -------------------------------------------------- |
|
|
79
79
|
| Zhipu GLM · DeepSeek · Qwen · Kimi · MiniMax … | Claude · Gemini · Grok · Mistral · Perplexity … | OpenRouter · Together · Ollama · LMStudio · vLLM … |
|
|
80
80
|
|
|
@@ -167,11 +167,11 @@ kaijibot gateway --port 18789 --verbose
|
|
|
167
167
|
**Required**: At least one LLM provider API key + Feishu bot credentials.
|
|
168
168
|
|
|
169
169
|
```bash
|
|
170
|
-
# LLM API Key
|
|
171
|
-
export ZAI_API_KEY="your-key" # Zhipu GLM
|
|
172
|
-
# export DEEPSEEK_API_KEY="your-key"
|
|
173
|
-
# export ANTHROPIC_API_KEY="your-key"
|
|
174
|
-
# export GOOGLE_API_KEY="your-key"
|
|
170
|
+
# LLM API Key — pick one provider, uncomment the corresponding line
|
|
171
|
+
# export ZAI_API_KEY="your-key" # Zhipu GLM
|
|
172
|
+
# export DEEPSEEK_API_KEY="your-key" # DeepSeek
|
|
173
|
+
# export ANTHROPIC_API_KEY="your-key" # Claude
|
|
174
|
+
# export GOOGLE_API_KEY="your-key" # Gemini
|
|
175
175
|
|
|
176
176
|
# Feishu channel
|
|
177
177
|
kaijibot config set channels.feishu.appId "your-app-id"
|
package/README.md
CHANGED
|
@@ -74,7 +74,7 @@ AI 助手每次新建会话都犯同样的错?KaijiBot 不会。它有一套
|
|
|
74
74
|
|
|
75
75
|
不绑死任何一家。国内国际随意切换,`kaijibot onboard` 向导自动发现已配置的 API Key。
|
|
76
76
|
|
|
77
|
-
|
|
|
77
|
+
| 国内 | 国际主流 | 聚合 / 自部署 |
|
|
78
78
|
| ------------------------------------------------- | ----------------------------------------------- | -------------------------------------------------- |
|
|
79
79
|
| 智谱 GLM · DeepSeek · 通义千问 · Kimi · MiniMax … | Claude · Gemini · Grok · Mistral · Perplexity … | OpenRouter · Together · Ollama · LMStudio · vLLM … |
|
|
80
80
|
|
|
@@ -110,7 +110,7 @@ kaijibot skills install <skill-name>
|
|
|
110
110
|
|
|
111
111
|
| 条件 | 说明 | 获取方式 |
|
|
112
112
|
|------|------|----------|
|
|
113
|
-
| **LLM API Key** | 至少一个 AI 提供商的密钥 |
|
|
113
|
+
| **LLM API Key** | 至少一个 AI 提供商的密钥 | [智谱 GLM](https://open.bigmodel.cn/) · [DeepSeek](https://platform.deepseek.com/) · [Claude](https://console.anthropic.com/) · [Gemini](https://aistudio.google.com/apikey) · [通义千问](https://dashscope.console.aliyun.com/) 任选其一 |
|
|
114
114
|
| **飞书账号** | 用于收发消息 | [open.feishu.cn](https://open.feishu.cn/) 注册即可,向导支持扫码自动创建机器人 |
|
|
115
115
|
|
|
116
116
|
### 安装(推荐方式)
|
|
@@ -202,11 +202,11 @@ kaijibot onboard # 交互式向导
|
|
|
202
202
|
**必需**:至少一个 LLM 提供商的 API Key + 飞书机器人凭证。
|
|
203
203
|
|
|
204
204
|
```bash
|
|
205
|
-
# LLM API Key
|
|
206
|
-
export ZAI_API_KEY="your-key" # 智谱 GLM
|
|
207
|
-
# export DEEPSEEK_API_KEY="your-key"
|
|
208
|
-
# export ANTHROPIC_API_KEY="your-key"
|
|
209
|
-
# export GOOGLE_API_KEY="your-key"
|
|
205
|
+
# LLM API Key — 任选一个提供商,取消对应行的注释
|
|
206
|
+
# export ZAI_API_KEY="your-key" # 智谱 GLM
|
|
207
|
+
# export DEEPSEEK_API_KEY="your-key" # DeepSeek
|
|
208
|
+
# export ANTHROPIC_API_KEY="your-key" # Claude
|
|
209
|
+
# export GOOGLE_API_KEY="your-key" # Gemini
|
|
210
210
|
|
|
211
211
|
# 飞书频道(也可在向导中扫码自动配置)
|
|
212
212
|
kaijibot config set channels.feishu.appId "your-app-id"
|
package/dist/.buildstamp
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"builtAt":
|
|
1
|
+
{"builtAt":1782525223520,"head":"7b3881a9023c6819a99dfcd4c6792020103270bd"}
|
package/dist/build-info.json
CHANGED
|
@@ -13,5 +13,5 @@
|
|
|
13
13
|
],
|
|
14
14
|
"channelCatalogSignature": "536c3403ef5a5e2c04e8579768c6cd9bbab05304",
|
|
15
15
|
"rootHelpBundleSignature": "f907d267a3c63b29d740c623d3e383aec5df15c9",
|
|
16
|
-
"rootHelpText": "\n👾 KaijiBot 2026.6.
|
|
16
|
+
"rootHelpText": "\n👾 KaijiBot 2026.6.28 (7b3881a) — 灵感不是等来的,是在持续思考中偶然相遇的。\n\nUsage: kaijibot [options] [command]\n\nOptions:\n --container <name> Run the CLI inside a running Podman/Docker container\n named <name> (default: env KAIJIBOT_CONTAINER)\n --dev Dev profile: isolate state under ~/.kaijibot-dev, default\n gateway port 19001, and shift derived ports\n (browser/canvas)\n -h, --help Display help for command\n --log-level <level> Global log level override for file + console\n (silent|fatal|error|warn|info|debug|trace)\n --no-color Disable ANSI colors\n --profile <name> Use a named profile (isolates\n KAIJIBOT_STATE_DIR/KAIJIBOT_CONFIG_PATH under\n ~/.kaijibot-<name>)\n -V, --version output the version number\n\nCommands:\n Hint: commands suffixed with * have subcommands. Run <command> --help for details.\n acp * Agent Control Protocol tools\n agent Run one agent turn via the Gateway\n agents * Manage isolated agents (workspaces, auth, routing)\n android-install Set up KaijiBot on Android/Termux (auto-installs\n packages, boot script, battery settings)\n approvals * Manage exec approvals (gateway or node host)\n backup * Create and verify local backup archives for KaijiBot\n state\n capability * Run provider-backed inference commands (fallback alias:\n infer)\n channels * Manage connected chat channels (Telegram, Discord, etc.)\n clawbot * Legacy clawbot command aliases\n completion Generate shell completion script\n config * Non-interactive config helpers\n (get/set/unset/file/validate). Default: starts guided\n setup.\n configure Interactive configuration for credentials, channels,\n gateway, and agent defaults\n cron * Manage cron jobs via the Gateway scheduler\n daemon * Gateway service (legacy alias)\n dashboard Open the Control UI with your current token\n devices * Device pairing + token management\n directory * Lookup contact and group IDs (self, peers, groups) for\n supported chat channels\n dns * DNS helpers for wide-area discovery (Tailscale + CoreDNS)\n docs Search the live KaijiBot docs\n doctor Health checks + quick fixes for the gateway and channels\n gateway * Run, inspect, and query the WebSocket Gateway\n health Fetch health from the running gateway\n help Display help for command\n hooks * Manage internal agent hooks\n infer * Run provider-backed inference commands\n logs Tail gateway file logs via RPC\n mcp * Manage KaijiBot MCP config and channel bridge\n memory Search, inspect, and reindex memory files\n message * Send, read, and manage messages\n migrate Migrate data from OpenClaw or legacy installations to\n KaijiBot\n models * Discover, scan, and configure models\n node * Run and manage the headless node host service\n nodes * Manage gateway-owned node pairing and node commands\n onboard Interactive onboarding for gateway, workspace, and skills\n pairing * Secure DM pairing (approve inbound requests)\n plugins * Manage KaijiBot plugins and extensions\n qa * Run QA scenarios and launch the private QA debugger UI\n qr Generate mobile pairing QR/setup code\n reset Reset local config/state (keeps the CLI installed)\n sandbox * Manage sandbox containers for agent isolation\n secrets * Secrets runtime reload controls\n security * Security tools and local config audits\n sessions * List stored conversation sessions\n setup Initialize local config and agent workspace\n skills * List and inspect available skills\n soul * Manage soul presets (MBTI-based personality profiles)\n status Show channel health and recent session recipients\n system * System events, heartbeat, and presence\n tasks * Inspect durable background task state\n tui Open a terminal UI connected to the Gateway\n uninstall Uninstall the gateway service + local data (CLI remains)\n update * Update KaijiBot and inspect update channel status\n webhooks * Webhook helpers and integrations\n\nExamples:\n kaijibot models --help\n Show detailed help for the models command.\n kaijibot channels login --verbose\n Link personal WhatsApp Web and show QR + connection logs.\n kaijibot message send --target +15555550123 --message \"Hi\" --json\n Send via your web session and print JSON result.\n kaijibot gateway --port 18789\n Run the WebSocket Gateway locally.\n kaijibot --dev gateway\n Run a dev Gateway (isolated state/config) on ws://127.0.0.1:19001.\n kaijibot gateway --force\n Kill anything bound to the default gateway port, then start it.\n kaijibot gateway ...\n Gateway control via WebSocket.\n kaijibot agent --to +15555550123 --message \"Run summary\" --deliver\n Talk directly to the agent using the Gateway; optionally send the WhatsApp reply.\n kaijibot message send --channel feishu --target ou_xxx --message \"Hi\"\n Send via your Telegram bot.\n\nDocs: https://gitee.com/kaiji1126/kaijibot/blob/main/docs/cli.md\n\n"
|
|
17
17
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { t as resolveCliArgvInvocation } from "./argv-invocation-CagzCjnZ.js";
|
|
2
2
|
import { n as shouldRegisterPrimaryCommandOnly } from "./command-registration-policy-hu4zlxIR.js";
|
|
3
|
-
import { a as defineImportedCommandGroupSpec, i as buildCommandGroupEntries, o as defineImportedProgramCommandGroupSpecs, r as registerSubCliCommands } from "./register.subclis-
|
|
3
|
+
import { a as defineImportedCommandGroupSpec, i as buildCommandGroupEntries, o as defineImportedProgramCommandGroupSpecs, r as registerSubCliCommands } from "./register.subclis-1xMEIUE-.js";
|
|
4
4
|
import { i as registerCommandGroups, r as registerCommandGroupByName } from "./register-command-groups-UMPXCoLt.js";
|
|
5
5
|
import { n as getCoreCliCommandNames$1, t as getCoreCliCommandDescriptors } from "./core-command-descriptors-CEjSWnul.js";
|
|
6
6
|
//#region src/cli/program/command-registry.ts
|
|
@@ -16,12 +16,12 @@ const coreEntrySpecs = [
|
|
|
16
16
|
...withProgramOnlySpecs(defineImportedProgramCommandGroupSpecs([
|
|
17
17
|
{
|
|
18
18
|
commandNames: ["setup"],
|
|
19
|
-
loadModule: () => import("./register.setup-
|
|
19
|
+
loadModule: () => import("./register.setup-BwhZ8gtj.js"),
|
|
20
20
|
exportName: "registerSetupCommand"
|
|
21
21
|
},
|
|
22
22
|
{
|
|
23
23
|
commandNames: ["onboard"],
|
|
24
|
-
loadModule: () => import("./register.onboard-
|
|
24
|
+
loadModule: () => import("./register.onboard-DuKKuVdd.js"),
|
|
25
25
|
exportName: "registerOnboardCommand"
|
|
26
26
|
},
|
|
27
27
|
{
|
|
@@ -46,7 +46,7 @@ const coreEntrySpecs = [
|
|
|
46
46
|
"reset",
|
|
47
47
|
"uninstall"
|
|
48
48
|
],
|
|
49
|
-
loadModule: () => import("./register.maintenance-
|
|
49
|
+
loadModule: () => import("./register.maintenance-CtPWHuwH.js"),
|
|
50
50
|
exportName: "registerMaintenanceCommands"
|
|
51
51
|
},
|
|
52
52
|
{
|
|
@@ -56,7 +56,7 @@ const coreEntrySpecs = [
|
|
|
56
56
|
},
|
|
57
57
|
{
|
|
58
58
|
commandNames: ["android-install"],
|
|
59
|
-
loadModule: () => import("./register.android-install-
|
|
59
|
+
loadModule: () => import("./register.android-install-BUvcr7Tz.js"),
|
|
60
60
|
exportName: "registerAndroidInstallCommand"
|
|
61
61
|
}
|
|
62
62
|
])),
|
|
@@ -4,8 +4,8 @@ import { c as routeLogsToStderr } from "./subsystem-vYBF7nSn.js";
|
|
|
4
4
|
import { t as formatDocsLink } from "./links-DG6HlfoL.js";
|
|
5
5
|
import { r as theme } from "./theme-BtqB6Mz_.js";
|
|
6
6
|
import { _ as resolveStateDir } from "./paths-DaKBKbjg.js";
|
|
7
|
-
import { n as registerSubCliByName, t as getSubCliEntries } from "./register.subclis-
|
|
8
|
-
import { n as registerCoreCliByName, t as getCoreCliCommandNames } from "./command-registry-
|
|
7
|
+
import { n as registerSubCliByName, t as getSubCliEntries } from "./register.subclis-1xMEIUE-.js";
|
|
8
|
+
import { n as registerCoreCliByName, t as getCoreCliCommandNames } from "./command-registry-DzfcgAoH.js";
|
|
9
9
|
import { t as getProgramContext } from "./program-context-Cf5AFJfm.js";
|
|
10
10
|
import path from "node:path";
|
|
11
11
|
import os from "node:os";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as registerCompletionCli, c as usesSlowDynamicCompletion, i as isCompletionInstalled, n as getCompletionScript, o as resolveCompletionCachePath, r as installCompletion, s as resolveShellFromEnv, t as completionCacheExists } from "./completion-cli-
|
|
1
|
+
import { a as registerCompletionCli, c as usesSlowDynamicCompletion, i as isCompletionInstalled, n as getCompletionScript, o as resolveCompletionCachePath, r as installCompletion, s as resolveShellFromEnv, t as completionCacheExists } from "./completion-cli-BHEov8Bb.js";
|
|
2
2
|
export { completionCacheExists, getCompletionScript, installCompletion, isCompletionInstalled, registerCompletionCli, resolveCompletionCachePath, resolveShellFromEnv, usesSlowDynamicCompletion };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as resolveKaijiBotPackageRoot } from "./kaijibot-root-BjhI7uOk.js";
|
|
2
2
|
import { n as resolveCliName } from "./cli-name-DhejotUr.js";
|
|
3
3
|
import { t as note } from "./note-Dq7aeSJr.js";
|
|
4
|
-
import { c as usesSlowDynamicCompletion, i as isCompletionInstalled, o as resolveCompletionCachePath, r as installCompletion, s as resolveShellFromEnv, t as completionCacheExists } from "./completion-cli-
|
|
4
|
+
import { c as usesSlowDynamicCompletion, i as isCompletionInstalled, o as resolveCompletionCachePath, r as installCompletion, s as resolveShellFromEnv, t as completionCacheExists } from "./completion-cli-BHEov8Bb.js";
|
|
5
5
|
import path from "node:path";
|
|
6
6
|
import { spawnSync } from "node:child_process";
|
|
7
7
|
//#region src/commands/doctor-completion.ts
|
package/dist/entry.js
CHANGED
|
@@ -203,7 +203,7 @@ function tryHandleRootHelpFastPath(argv, deps = {}) {
|
|
|
203
203
|
}
|
|
204
204
|
function runMainOrRootHelp(argv) {
|
|
205
205
|
if (tryHandleRootHelpFastPath(argv)) return;
|
|
206
|
-
import("./run-main-
|
|
206
|
+
import("./run-main-ONomAiDX.js").then(({ runCli }) => runCli(argv)).catch((error) => {
|
|
207
207
|
console.error("[kaijibot] Failed to start CLI:", error instanceof Error ? error.stack ?? error.message : error);
|
|
208
208
|
process$1.exitCode = 1;
|
|
209
209
|
});
|
|
@@ -1173,7 +1173,7 @@ async function runGatewayCommand$1(opts) {
|
|
|
1173
1173
|
const { startGatewayServer } = await withProgress({
|
|
1174
1174
|
label: "Loading gateway modules…",
|
|
1175
1175
|
indeterminate: true
|
|
1176
|
-
}, async () => import("./server-
|
|
1176
|
+
}, async () => import("./server-C3w72H_f.js"));
|
|
1177
1177
|
setConsoleTimestampPrefix(true);
|
|
1178
1178
|
if (devMode) await ensureDevGatewayConfig({ reset: Boolean(opts.reset) });
|
|
1179
1179
|
gatewayLog.info("loading configuration…");
|
package/dist/index.js
CHANGED
|
@@ -26,7 +26,7 @@ let runExec;
|
|
|
26
26
|
let saveSessionStore;
|
|
27
27
|
let waitForever;
|
|
28
28
|
async function loadLegacyCliDeps() {
|
|
29
|
-
const [{ installGaxiosFetchCompat }, { runCli }] = await Promise.all([import("./gaxios-fetch-compat-D6MKaF6d.js"), import("./run-main-
|
|
29
|
+
const [{ installGaxiosFetchCompat }, { runCli }] = await Promise.all([import("./gaxios-fetch-compat-D6MKaF6d.js"), import("./run-main-ONomAiDX.js")]);
|
|
30
30
|
return {
|
|
31
31
|
installGaxiosFetchCompat,
|
|
32
32
|
runCli
|
|
@@ -16,7 +16,7 @@ import { t as WizardCancelledError } from "./prompts-DreY0gp7.js";
|
|
|
16
16
|
import { n as logConfigUpdated } from "./logging-CwpXJK_x.js";
|
|
17
17
|
import { t as createClackPrompter } from "./clack-prompter-jKNc7rzV.js";
|
|
18
18
|
import { c as resolveManifestProviderOnboardAuthFlags, i as resolveDeprecatedAuthChoiceReplacement, n as isDeprecatedAuthChoice, r as normalizeLegacyOnboardAuthChoice, t as formatDeprecatedNonInteractiveAuthChoiceError } from "./auth-choice-legacy-C_CO25Kx.js";
|
|
19
|
-
import { t as runSetupWizard } from "./setup-
|
|
19
|
+
import { t as runSetupWizard } from "./setup-BGZo-_Jf.js";
|
|
20
20
|
import { r as applyLocalSetupWorkspaceConfig } from "./onboard-config-BXe45WpU.js";
|
|
21
21
|
//#region src/commands/onboard-core-auth-flags.ts
|
|
22
22
|
const CORE_ONBOARD_AUTH_FLAGS = [];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
2026-06-27T01:
|
|
1
|
+
2026-06-27T01:54:42.559Z
|
|
@@ -4,7 +4,7 @@ import { n as VERSION } from "./version-Bhg28AYn.js";
|
|
|
4
4
|
import "./globals-pIWF87AA.js";
|
|
5
5
|
import { n as resolveCliName } from "./cli-name-DhejotUr.js";
|
|
6
6
|
import { n as resolveCliChannelOptions } from "./channel-options-Cc0fBcfx.js";
|
|
7
|
-
import { i as registerProgramCommands } from "./command-registry-
|
|
7
|
+
import { i as registerProgramCommands } from "./command-registry-DzfcgAoH.js";
|
|
8
8
|
import { n as setProgramContext } from "./program-context-Cf5AFJfm.js";
|
|
9
9
|
import { t as isCommandJsonOutputMode } from "./json-mode-BYm5jctq.js";
|
|
10
10
|
import { t as forceFreePort } from "./ports-_vH4tRcr.js";
|
|
@@ -111,7 +111,7 @@ import { t as ensureSystemdUserLingerInteractive } from "./systemd-linger-vNyJlQ
|
|
|
111
111
|
import { t as formatHealthCheckFailure } from "./health-format-O1soTHOK.js";
|
|
112
112
|
import { a as stripUnknownConfigKeys, i as resolveConfigPathTarget, n as formatConfigPath, r as noteOpencodeProviderOverrides, t as runDoctorConfigPreflight } from "./doctor-config-preflight-D9YPlAdr.js";
|
|
113
113
|
import { a as runChannelPluginStartupMaintenance, i as normalizeCronJobIdentityFields, t as coerceFiniteScheduleNumber } from "./schedule-DZui-rZG.js";
|
|
114
|
-
import { n as doctorShellCompletion } from "./doctor-completion-
|
|
114
|
+
import { n as doctorShellCompletion } from "./doctor-completion-CCRmJ8E_.js";
|
|
115
115
|
import { t as collectChannelStatusIssues } from "./channels-status-issues-C83kcrs9.js";
|
|
116
116
|
import { t as resolveDefaultChannelAccountContext } from "./channel-account-context-CVLJKsM0.js";
|
|
117
117
|
import { a as runLegacyStateMigrations, n as detectLegacyStateMigrations } from "./state-migrations-Bkk-89ZL.js";
|
|
@@ -3,10 +3,11 @@ import { r as theme } from "./theme-BtqB6Mz_.js";
|
|
|
3
3
|
import { i as writeTextAtomic } from "./json-files-DjWhPU3s.js";
|
|
4
4
|
import { n as runCommandWithRuntime } from "./cli-utils-BHumzKxD.js";
|
|
5
5
|
import { t as formatHelpExamples } from "./help-format-C4SFxWlm.js";
|
|
6
|
+
import { accessSync, constants } from "node:fs";
|
|
6
7
|
import path from "node:path";
|
|
7
8
|
import { spawn, spawnSync } from "node:child_process";
|
|
8
9
|
import os from "node:os";
|
|
9
|
-
import fs from "node:fs/promises";
|
|
10
|
+
import fs$1 from "node:fs/promises";
|
|
10
11
|
//#region src/commands/android-install.ts
|
|
11
12
|
const REQUIRED_PACKAGES = [
|
|
12
13
|
"git",
|
|
@@ -81,6 +82,26 @@ function runText(cmd, args, options = {}) {
|
|
|
81
82
|
if (typeof result.stdout === "string") return result.stdout.trim();
|
|
82
83
|
return result.stdout.toString("utf8").trim();
|
|
83
84
|
}
|
|
85
|
+
/**
|
|
86
|
+
* Locate a binary on PATH. Uses `command -v` via shell (POSIX standard)
|
|
87
|
+
* because `which` is not guaranteed to exist on Termux/Android.
|
|
88
|
+
*/
|
|
89
|
+
function findBinary(name) {
|
|
90
|
+
const result = spawnSync("sh", ["-c", `command -v "${name}"`], DEFAULT_SPAWN_OPTIONS);
|
|
91
|
+
if (result.status === 0 && typeof result.stdout === "string") {
|
|
92
|
+
const found = result.stdout.trim();
|
|
93
|
+
if (found.length > 0) return found;
|
|
94
|
+
}
|
|
95
|
+
const prefix = process.env.PREFIX;
|
|
96
|
+
if (prefix) {
|
|
97
|
+
const candidate = path.join(prefix, "bin", name);
|
|
98
|
+
try {
|
|
99
|
+
accessSync(candidate, constants.X_OK);
|
|
100
|
+
return candidate;
|
|
101
|
+
} catch {}
|
|
102
|
+
}
|
|
103
|
+
return "";
|
|
104
|
+
}
|
|
84
105
|
function parseNodeMajor(versionText) {
|
|
85
106
|
const match = /v?(\d+)\./.exec(versionText);
|
|
86
107
|
if (!match) return null;
|
|
@@ -123,9 +144,9 @@ async function ensureNode(runtime) {
|
|
|
123
144
|
}
|
|
124
145
|
async function ensureRequiredPackages(runtime) {
|
|
125
146
|
for (const pkg of REQUIRED_PACKAGES) {
|
|
126
|
-
const
|
|
127
|
-
if (
|
|
128
|
-
runtime.log(` ${theme.success("✓")} ${pkg} (${theme.muted(
|
|
147
|
+
const found = findBinary(pkg);
|
|
148
|
+
if (found.length > 0) {
|
|
149
|
+
runtime.log(` ${theme.success("✓")} ${pkg} (${theme.muted(found)})`);
|
|
129
150
|
continue;
|
|
130
151
|
}
|
|
131
152
|
runtime.log(` ${theme.warn("→")} ${pkg} not found. Installing via pkg...`);
|
|
@@ -134,7 +155,7 @@ async function ensureRequiredPackages(runtime) {
|
|
|
134
155
|
"-y",
|
|
135
156
|
pkg
|
|
136
157
|
]);
|
|
137
|
-
if (
|
|
158
|
+
if (findBinary(pkg).length === 0) {
|
|
138
159
|
runtime.error(`Failed to install ${pkg}. Please run ${theme.command(`pkg install ${pkg}`)} manually.`);
|
|
139
160
|
runtime.exit(1);
|
|
140
161
|
return;
|
|
@@ -199,7 +220,7 @@ async function writeBootScript(runtime) {
|
|
|
199
220
|
ensureDirMode: 493
|
|
200
221
|
});
|
|
201
222
|
try {
|
|
202
|
-
await fs.chmod(bootPath, BOOT_SCRIPT_MODE);
|
|
223
|
+
await fs$1.chmod(bootPath, BOOT_SCRIPT_MODE);
|
|
203
224
|
} catch {}
|
|
204
225
|
runtime.log(` ${theme.success("✓")} Boot script written: ${theme.accent(bootPath)}`);
|
|
205
226
|
}
|
|
@@ -207,7 +228,7 @@ async function writeBashrcAutostart(runtime) {
|
|
|
207
228
|
const bashrcPath = path.join(os.homedir(), ".bashrc");
|
|
208
229
|
let existing = "";
|
|
209
230
|
try {
|
|
210
|
-
existing = await fs.readFile(bashrcPath, "utf8");
|
|
231
|
+
existing = await fs$1.readFile(bashrcPath, "utf8");
|
|
211
232
|
} catch {
|
|
212
233
|
existing = "";
|
|
213
234
|
}
|
|
@@ -299,7 +320,7 @@ async function ensureAllowExternalApps(runtime) {
|
|
|
299
320
|
const propsPath = path.join(os.homedir(), ".termux", "termux.properties");
|
|
300
321
|
let existing = "";
|
|
301
322
|
try {
|
|
302
|
-
existing = await fs.readFile(propsPath, "utf8");
|
|
323
|
+
existing = await fs$1.readFile(propsPath, "utf8");
|
|
303
324
|
} catch {
|
|
304
325
|
existing = "";
|
|
305
326
|
}
|
|
@@ -15,7 +15,7 @@ import { i as formatControlUiSshHint } from "./onboard-helpers-BUUSQ2PE.js";
|
|
|
15
15
|
import { r as resolveGatewayService } from "./service-Dw1RhCOk.js";
|
|
16
16
|
import { a as removeStateAndLinkedPaths, i as removePath, o as removeWorkspaceDirs, r as listAgentSessionDirs, t as buildCleanupPlan } from "./cleanup-utils-CzBXz009.js";
|
|
17
17
|
import { n as runCommandWithRuntime } from "./cli-utils-BHumzKxD.js";
|
|
18
|
-
import { n as doctorCommand, t as selectStyled } from "./prompt-select-styled-
|
|
18
|
+
import { n as doctorCommand, t as selectStyled } from "./prompt-select-styled-CSbxwMaJ.js";
|
|
19
19
|
import path from "node:path";
|
|
20
20
|
import { cancel, confirm, isCancel, multiselect } from "@clack/prompts";
|
|
21
21
|
//#region src/infra/clipboard.ts
|
|
@@ -4,7 +4,7 @@ import { r as theme } from "./theme-BtqB6Mz_.js";
|
|
|
4
4
|
import { n as runCommandWithRuntime } from "./cli-utils-BHumzKxD.js";
|
|
5
5
|
import { c as resolveManifestProviderOnboardAuthFlags } from "./auth-choice-legacy-C_CO25Kx.js";
|
|
6
6
|
import { n as formatAuthChoiceChoicesForCli } from "./auth-choice-options-Cz7b978t.js";
|
|
7
|
-
import { n as CORE_ONBOARD_AUTH_FLAGS, t as setupWizardCommand } from "./onboard-
|
|
7
|
+
import { n as CORE_ONBOARD_AUTH_FLAGS, t as setupWizardCommand } from "./onboard-CiaJ_cr1.js";
|
|
8
8
|
//#region src/cli/program/register.onboard.ts
|
|
9
9
|
function resolveInstallDaemonFlag(command, opts) {
|
|
10
10
|
if (!command || typeof command !== "object") return;
|
|
@@ -11,7 +11,7 @@ import { s as resolveSessionTranscriptsDir } from "./paths-DGJB77Ow.js";
|
|
|
11
11
|
import { n as safeParseWithSchema } from "./zod-parse-CNYj_UND.js";
|
|
12
12
|
import { n as logConfigUpdated, t as formatConfigPath } from "./logging-CwpXJK_x.js";
|
|
13
13
|
import { n as runCommandWithRuntime } from "./cli-utils-BHumzKxD.js";
|
|
14
|
-
import { t as setupWizardCommand } from "./onboard-
|
|
14
|
+
import { t as setupWizardCommand } from "./onboard-CiaJ_cr1.js";
|
|
15
15
|
import fs from "node:fs/promises";
|
|
16
16
|
import JSON5 from "json5";
|
|
17
17
|
import { z } from "zod";
|
|
@@ -58,7 +58,7 @@ const entrySpecs = [
|
|
|
58
58
|
},
|
|
59
59
|
{
|
|
60
60
|
commandNames: ["gateway"],
|
|
61
|
-
loadModule: () => import("./gateway-cli-
|
|
61
|
+
loadModule: () => import("./gateway-cli-DiZwD1jt.js"),
|
|
62
62
|
exportName: "registerGatewayCli"
|
|
63
63
|
},
|
|
64
64
|
{
|
|
@@ -206,12 +206,12 @@ const entrySpecs = [
|
|
|
206
206
|
},
|
|
207
207
|
{
|
|
208
208
|
commandNames: ["update"],
|
|
209
|
-
loadModule: () => import("./update-cli-
|
|
209
|
+
loadModule: () => import("./update-cli-DBKmpmBG.js"),
|
|
210
210
|
exportName: "registerUpdateCli"
|
|
211
211
|
},
|
|
212
212
|
{
|
|
213
213
|
commandNames: ["completion"],
|
|
214
|
-
loadModule: () => import("./completion-cli-
|
|
214
|
+
loadModule: () => import("./completion-cli-DSFwqqKQ.js"),
|
|
215
215
|
exportName: "registerCompletionCli"
|
|
216
216
|
}
|
|
217
217
|
])
|
|
@@ -395,7 +395,7 @@ async function runCli(argv = process$1.argv) {
|
|
|
395
395
|
if (await tryRouteCli(normalizedArgv)) return;
|
|
396
396
|
enableConsoleCapture();
|
|
397
397
|
const [{ buildProgram }, { installUnhandledRejectionHandler }, { restoreTerminalState }] = await Promise.all([
|
|
398
|
-
import("./program-
|
|
398
|
+
import("./program-B4Lh9HnH.js"),
|
|
399
399
|
import("./unhandled-rejections-B7jiLc5X.js"),
|
|
400
400
|
import("./restore-ADlpnb-M.js")
|
|
401
401
|
]);
|
|
@@ -412,10 +412,10 @@ async function runCli(argv = process$1.argv) {
|
|
|
412
412
|
const { getProgramContext } = await import("./program-context-DnhaNGWO.js");
|
|
413
413
|
const ctx = getProgramContext(program);
|
|
414
414
|
if (ctx) {
|
|
415
|
-
const { registerCoreCliByName } = await import("./command-registry-
|
|
415
|
+
const { registerCoreCliByName } = await import("./command-registry-DMdu_t1F.js");
|
|
416
416
|
await registerCoreCliByName(program, ctx, primary, parseArgv);
|
|
417
417
|
}
|
|
418
|
-
const { registerSubCliByName } = await import("./register.subclis-
|
|
418
|
+
const { registerSubCliByName } = await import("./register.subclis-CjiauVD0.js");
|
|
419
419
|
await registerSubCliByName(program, primary);
|
|
420
420
|
}
|
|
421
421
|
if (!shouldSkipPluginCommandRegistration({
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as truncateCloseReason } from "./close-reason-nz_ERN9v.js";
|
|
2
2
|
//#region src/gateway/server.ts
|
|
3
3
|
async function loadServerImpl() {
|
|
4
|
-
return await import("./server.impl-
|
|
4
|
+
return await import("./server.impl-sokp10QV.js");
|
|
5
5
|
}
|
|
6
6
|
async function startGatewayServer(...args) {
|
|
7
7
|
return await (await loadServerImpl()).startGatewayServer(...args);
|
|
@@ -196,7 +196,7 @@ import { t as loadWorkspaceHookEntries } from "./workspace-Cy_NTL1s.js";
|
|
|
196
196
|
import { i as resolveGatewayStartupPluginIds, r as resolveConfiguredDeferredChannelPluginIds } from "./channel-plugin-ids-Ci_TMEH5.js";
|
|
197
197
|
import { a as runChannelPluginStartupMaintenance, i as normalizeCronJobIdentityFields, n as computeNextRunAtMs, r as computePreviousRunAtMs, t as coerceFiniteScheduleNumber } from "./schedule-DZui-rZG.js";
|
|
198
198
|
import { i as migrateOrphanedSessionKeys } from "./state-migrations-Bkk-89ZL.js";
|
|
199
|
-
import { t as runSetupWizard } from "./setup-
|
|
199
|
+
import { t as runSetupWizard } from "./setup-BGZo-_Jf.js";
|
|
200
200
|
import { d as startTaskRegistryMaintenance, f as stopTaskRegistryMaintenance, g as markCronJobActive, h as clearCronJobActive, n as getInspectableTaskRegistrySummary } from "./task-registry.maintenance-CjqmDflg.js";
|
|
201
201
|
import { n as collectEnabledInsecureOrDangerousFlags, t as DEFAULT_GATEWAY_HTTP_TOOL_DENY } from "./dangerous-tools-BhrFAots.js";
|
|
202
202
|
import { _ as buildGogWatchStartArgs, g as buildGogWatchServeArgs, i as ensureTailscaleEndpoint, w as resolveGmailHookRuntimeConfig } from "./gmail-setup-utils-DKB_7B1z.js";
|
|
@@ -62,9 +62,12 @@ async function showPrerequisiteChecklist(prompter) {
|
|
|
62
62
|
"开始前请准备好以下条件:",
|
|
63
63
|
"",
|
|
64
64
|
" 1. LLM API Key(必需)",
|
|
65
|
-
"
|
|
66
|
-
"
|
|
67
|
-
"
|
|
65
|
+
" 任选一个 AI 提供商注册并创建 API Key:",
|
|
66
|
+
" 智谱 GLM:https://open.bigmodel.cn/",
|
|
67
|
+
" DeepSeek:https://platform.deepseek.com/",
|
|
68
|
+
" Anthropic Claude:https://console.anthropic.com/",
|
|
69
|
+
" Google Gemini:https://aistudio.google.com/apikey",
|
|
70
|
+
" 通义千问:https://dashscope.console.aliyun.com/",
|
|
68
71
|
"",
|
|
69
72
|
" 2. 飞书账号(必需)",
|
|
70
73
|
" 向导中可选「扫码自动创建飞书机器人」,10 秒搞定",
|
|
@@ -371,7 +374,7 @@ async function runSetupWizard(opts, runtime = defaultRuntime, prompter) {
|
|
|
371
374
|
await prompter.note([
|
|
372
375
|
"选择你的 AI 提供商。如需注册 API Key:",
|
|
373
376
|
"",
|
|
374
|
-
" 智谱 GLM
|
|
377
|
+
" 智谱 GLM:https://open.bigmodel.cn/",
|
|
375
378
|
" DeepSeek:https://platform.deepseek.com/",
|
|
376
379
|
" Anthropic Claude:https://console.anthropic.com/",
|
|
377
380
|
" Google Gemini:https://aistudio.google.com/apikey",
|
|
@@ -517,7 +520,7 @@ async function runSetupWizard(opts, runtime = defaultRuntime, prompter) {
|
|
|
517
520
|
mode
|
|
518
521
|
});
|
|
519
522
|
await writeConfigFile(nextConfig);
|
|
520
|
-
const { finalizeSetupWizard } = await import("./setup.finalize-
|
|
523
|
+
const { finalizeSetupWizard } = await import("./setup.finalize-BdGsks0i.js");
|
|
521
524
|
const { launchedTui } = await finalizeSetupWizard({
|
|
522
525
|
flow,
|
|
523
526
|
opts,
|
|
@@ -13,11 +13,11 @@ import { i as isSystemdUserServiceAvailable } from "./systemd-uX5teojQ.js";
|
|
|
13
13
|
import { a as tryResolveGatewayService, t as describeGatewayServiceRestart } from "./service-Dw1RhCOk.js";
|
|
14
14
|
import { n as listConfiguredWebSearchProviders } from "./runtime-DqpFgWdf.js";
|
|
15
15
|
import { t as ensureControlUiAssetsBuilt } from "./control-ui-assets-Cs8f1qtt.js";
|
|
16
|
-
import { r as installCompletion } from "./completion-cli-
|
|
16
|
+
import { r as installCompletion } from "./completion-cli-BHEov8Bb.js";
|
|
17
17
|
import { r as healthCommand } from "./health-C2kZ493G.js";
|
|
18
18
|
import { t as resolveSetupSecretInputString } from "./setup.secret-input-ove9iGYd.js";
|
|
19
19
|
import { t as formatHealthCheckFailure } from "./health-format-O1soTHOK.js";
|
|
20
|
-
import { r as ensureCompletionCacheExists, t as checkShellCompletionStatus } from "./doctor-completion-
|
|
20
|
+
import { r as ensureCompletionCacheExists, t as checkShellCompletionStatus } from "./doctor-completion-CCRmJ8E_.js";
|
|
21
21
|
import { t as runTui } from "./tui-q-hs6XtN.js";
|
|
22
22
|
import path from "node:path";
|
|
23
23
|
import os from "node:os";
|
|
@@ -28,10 +28,10 @@ import { d as formatUpdateChannelLabel, g as resolveUpdateChannelDisplay, h as r
|
|
|
28
28
|
import { i as resolveUpdateAvailability, n as formatUpdateOneLiner, t as formatUpdateAvailableHint } from "./status.update-CL2My__e.js";
|
|
29
29
|
import { a as createGlobalInstallEnv, c as globalInstallArgs, d as resolveGlobalInstallTarget, f as normalizePackageTagInput, i as collectInstalledGlobalPackageErrors, l as resolveExpectedInstalledVersionFromSpec, m as readPackageVersion, n as canResolveRegistryVersionForPackageTarget, o as detectGlobalInstallManagerByPresence, p as readPackageName, r as cleanupGlobalRenameDirs, s as detectGlobalInstallManagerForRoot, t as runGatewayUpdate, u as resolveGlobalInstallSpec } from "./update-runner-twiNdDMV.js";
|
|
30
30
|
import { n as renderTable, t as getTerminalTableWidth } from "./table-DubuTY7u.js";
|
|
31
|
-
import { r as installCompletion } from "./completion-cli-
|
|
31
|
+
import { r as installCompletion } from "./completion-cli-BHEov8Bb.js";
|
|
32
32
|
import { n as updateNpmInstalledPlugins, t as syncPluginsForUpdateChannel } from "./update-CzeL9dWD.js";
|
|
33
|
-
import { n as doctorCommand, t as selectStyled } from "./prompt-select-styled-
|
|
34
|
-
import { r as ensureCompletionCacheExists, t as checkShellCompletionStatus } from "./doctor-completion-
|
|
33
|
+
import { n as doctorCommand, t as selectStyled } from "./prompt-select-styled-CSbxwMaJ.js";
|
|
34
|
+
import { r as ensureCompletionCacheExists, t as checkShellCompletionStatus } from "./doctor-completion-CCRmJ8E_.js";
|
|
35
35
|
import path from "node:path";
|
|
36
36
|
import { spawn, spawnSync } from "node:child_process";
|
|
37
37
|
import os from "node:os";
|