skykoi 2026.3.40 → 2026.3.42
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/dist/{SKYKOI-root-AZiQv7tD.js → SKYKOI-root-B5HYTPZX.js} +2 -2
- package/dist/{accounts-BVj7wD7a.js → accounts-CnTxg3dy.js} +7 -7
- package/dist/{acp-cli-DnKcMnWw.js → acp-cli-CpuqSfxE.js} +2 -2
- package/dist/{acp-cli-Co2ojfg_.js → acp-cli-Dct4qvak.js} +4 -4
- package/dist/{agent-Ml5azn6Z.js → agent-1yUpWtsp.js} +10 -10
- package/dist/{agent-WpP68gCK.js → agent-sD_-VQQ5.js} +6 -6
- package/dist/{agent-scope-DNm5APaI.js → agent-scope-C-oITVZT.js} +11 -11
- package/dist/{archive-jA3NtOTU.js → archive-B7z71oiV.js} +9 -9
- package/dist/{audit-BofNAKFx.js → audit-CQN8OO1t.js} +4 -4
- package/dist/{audit-zpAGRw4r.js → audit-Cby0wP0x.js} +16 -16
- package/dist/{auth-health-D84zwToy.js → auth-health-CYc6Lu9i.js} +1 -1
- package/dist/{auth-profiles-Dl4AWMpB.js → auth-profiles-BJV-XXxt.js} +1 -1
- package/dist/build-info.json +3 -3
- package/dist/{call-aRVe3g49.js → call-BsO3DxiF.js} +8 -8
- package/dist/{call-wa7Gy_M7.js → call-DA_VivF7.js} +1 -1
- package/dist/canvas-host/a2ui/.bundle.hash +1 -1
- package/dist/{channel-options-tVc0T8K3.js → channel-options-Bwi6Svoj.js} +3 -3
- package/dist/{channel-options-DF-LKLds.js → channel-options-nSOAfVf6.js} +2 -2
- package/dist/{channel-selection-BY1UQehW.js → channel-selection-B1jlZvso.js} +1 -1
- package/dist/{channel-summary-BmdepLga.js → channel-summary-DJhMycuy.js} +5 -5
- package/dist/{channel-summary-ZI618FLF.js → channel-summary-i03hulmw.js} +3 -3
- package/dist/{channels-cli-DebosrUJ.js → channels-cli-Bm-NLO6j.js} +36 -36
- package/dist/{channels-cli-BxlpiDEL.js → channels-cli-CFeRKN_1.js} +15 -15
- package/dist/{channels-status-issues-B7_2BFtg.js → channels-status-issues-Cx4DwKM8.js} +1 -1
- package/dist/cli/daemon-cli.js +1 -1
- package/dist/{cli-Ulpv-fk6.js → cli-B2f9TBnY.js} +13 -13
- package/dist/{cli-n6c4nxvy.js → cli-BvbEYSyO.js} +25 -25
- package/dist/{command-options-C-4ts3NY.js → command-options-CebL-fVk.js} +3 -3
- package/dist/{commands-DJNihRJq.js → commands-C9c-lr8S.js} +3 -3
- package/dist/{completion-cli-DckMZBnO.js → completion-cli-B5V3OVI6.js} +26 -26
- package/dist/{completion-cli-h9mpTe0h.js → completion-cli-D2wcH9xL.js} +13 -13
- package/dist/{config-DotRAQmF.js → config-DTSb2B10.js} +2 -1
- package/dist/{config-ZVT-gMSB.js → config-DxY4DsNc.js} +4 -3
- package/dist/{config-guard-KJYp3wpL.js → config-guard-NAIvHfQB.js} +34 -34
- package/dist/{config-CVSdvcRA.js → config-nVdFpcsN.js} +2 -1
- package/dist/{configure-D0wosY-y.js → configure-1OzriJYe.js} +6 -6
- package/dist/{configure-DK-wQSGu.js → configure-BOlIPgRO.js} +10 -10
- package/dist/{control-service-BEliJWU5.js → control-service-Bldt0O2x.js} +1 -1
- package/dist/{control-service-DigxECTw.js → control-service-DgQpJnpc.js} +4 -4
- package/dist/{cron-cli-C2Nqry4P.js → cron-cli-CfFKfEGV.js} +7 -7
- package/dist/{cron-cli-C_qmKBqW.js → cron-cli-D6vmrtzn.js} +3 -3
- package/dist/{daemon-cli-Cre4ymMI.js → daemon-cli-D6NAlRH7.js} +11 -11
- package/dist/{daemon-cli-CIlRkWUt.js → daemon-cli-DC5iIhr3.js} +7 -7
- package/dist/{daemon-runtime-BkjrfYdN.js → daemon-runtime-BK6HirWQ.js} +10 -10
- package/dist/{daemon-runtime-D3XrX8jd.js → daemon-runtime-BayngMTF.js} +1 -1
- package/dist/{deliver-BHio1uEH.js → deliver-5iHaga2j.js} +7 -7
- package/dist/{deliver-pRvfS38a.js → deliver-BQVz85YI.js} +4 -4
- package/dist/{deliver-Df2Vc7ss.js → deliver-DvaXZ6lQ.js} +2 -2
- package/dist/{deps-CJWFa9Lx.js → deps-Bh3TqNB-.js} +2 -2
- package/dist/{deps-CiSc8Rmn.js → deps-QpJPsy_z.js} +2 -2
- package/dist/{devices-cli-CxYNw2wz.js → devices-cli--j3l0-Y8.js} +4 -4
- package/dist/{devices-cli-BCUWSUAB.js → devices-cli-Y-HgUAkb.js} +2 -2
- package/dist/{directory-cli-B0qhe-2c.js → directory-cli-DRYU4YY0.js} +1 -1
- package/dist/{directory-cli-CvMOxl0Q.js → directory-cli-ZkKlq8eh.js} +6 -6
- package/dist/{dispatcher-Lf8eF4Ik.js → dispatcher-Cq5tmp_D.js} +1 -1
- package/dist/{dns-cli-D4S7e1SH.js → dns-cli-CBi77Ttb.js} +3 -3
- package/dist/{dns-cli-ejF3pFoo.js → dns-cli-DYV3Pjet.js} +1 -1
- package/dist/{docs-cli-C9c1IE5_.js → docs-cli-BDOiFw-y.js} +1 -1
- package/dist/{doctor-5NgvnQHt.js → doctor-C5msTpTy.js} +33 -33
- package/dist/{doctor-Cb3xmQ98.js → doctor-C7TRY86F.js} +9 -9
- package/dist/entry.js +1 -1
- package/dist/{errors-CDv4N5sG.js → errors-B_oMOHSO.js} +2 -2
- package/dist/{exec-approvals-cli-BSI2Fy5p.js → exec-approvals-cli-DPX09Wrh.js} +11 -11
- package/dist/{exec-approvals-cli-C7c-nUXU.js → exec-approvals-cli-PuOydi2E.js} +4 -4
- package/dist/extensionAPI.js +8 -8
- package/dist/{gateway-cli-BNcu9vUV.js → gateway-cli-B7S2Uq8P.js} +130 -119
- package/dist/{gateway-cli-DhV1sZEt.js → gateway-cli-DqkKLgtf.js} +43 -32
- package/dist/{gateway-rpc-B5LKwKPr.js → gateway-rpc-ClnqshEE.js} +1 -1
- package/dist/{gateway-rpc-b3bu9cbn.js → gateway-rpc-JqYMK2zC.js} +1 -1
- package/dist/{github-copilot-auth-na-mgwYB.js → github-copilot-auth-DXz3a3E2.js} +5 -5
- package/dist/{github-copilot-auth-D1eKRdDP.js → github-copilot-auth-Dpy1lEOb.js} +3 -3
- package/dist/{gmail-setup-utils-C93p0IzP.js → gmail-setup-utils-4SK5msI5.js} +1 -1
- package/dist/{health-format-CoPcVvS_.js → health-format-BOsDk3CA.js} +11 -11
- package/dist/{health-format-DWeqky5j.js → health-format-DAVONZbr.js} +5 -5
- package/dist/{hooks-cli-B-uj7kBc.js → hooks-cli-CBjq6YgU.js} +14 -14
- package/dist/{hooks-cli-nFyFT44X.js → hooks-cli-D4HIBkZB.js} +49 -49
- package/dist/{hooks-status-Cmci_pTC.js → hooks-status-k4MUOGQH.js} +1 -1
- package/dist/{image-Zj1KiGb5.js → image-CPiKCP7h.js} +2 -2
- package/dist/{image-D74VjmDV.js → image-s2xOdJ6i.js} +8 -8
- package/dist/{image-BpSb8ABB.js → image-szyjg5wy.js} +2 -2
- package/dist/index.js +31 -31
- package/dist/{installs-CFgC99LI.js → installs-CSjAIvjg.js} +18 -18
- package/dist/{loader-De3uQvTm.js → loader-DJZg0qBH.js} +115 -115
- package/dist/{login-qr-DmpXvBTg.js → login-qr-BgffN-K5.js} +2 -2
- package/dist/{login-qr-pGaE08Jw.js → login-qr-Cz4Uq-2A.js} +1 -1
- package/dist/{login-qr-CvqED8XU.js → login-qr-D81xG5SB.js} +1 -1
- package/dist/{logs-cli-BwLRM7a9.js → logs-cli-BH9lpmfs.js} +3 -3
- package/dist/{logs-cli-D3w6NNoj.js → logs-cli-LD-0rld_.js} +5 -5
- package/dist/{manager-IewkLSaD.js → manager-DZ9vDFG9.js} +15 -15
- package/dist/{models-cli-D56GkxjG.js → models-cli-B7gTZZXJ.js} +30 -30
- package/dist/{models-cli-CdzPMNh3.js → models-cli-NetlNf4S.js} +14 -14
- package/dist/{node-cli-hBtrIjBK.js → node-cli-B_8S1npG.js} +14 -14
- package/dist/{node-cli-umSprPTK.js → node-cli-CdDBJspJ.js} +6 -6
- package/dist/{node-service-Bn3J24RH.js → node-service-CZ2f4t4z.js} +1 -1
- package/dist/{nodes-cli-Cndqeeh0.js → nodes-cli-CSRjTW2l.js} +8 -8
- package/dist/{nodes-cli-VUmLZZ-L.js → nodes-cli-Dp85aozS.js} +3 -3
- package/dist/{nodes-screen-B4k0elxc.js → nodes-screen-COmr4MnV.js} +2 -2
- package/dist/{onboard-channels-BPqCKCSu.js → onboard-channels-CV-Ba-gi.js} +1 -1
- package/dist/{onboard-channels-BJ2ZpGj_.js → onboard-channels-CsDfqDWQ.js} +5 -5
- package/dist/{onboard-skills-CPbfCYux.js → onboard-skills-CGgzTn6B.js} +4 -4
- package/dist/{onboard-skills-BWL_rIu0.js → onboard-skills-DxXv_BdP.js} +9 -9
- package/dist/{onboarding-Bk8sYZKd.js → onboarding-BxDEKvJS.js} +14 -14
- package/dist/{pairing-cli-6LJJ014k.js → pairing-cli-D-PBMy6R.js} +1 -1
- package/dist/{pairing-cli-wmMF5wqN.js → pairing-cli-DklxuKv5.js} +7 -7
- package/dist/{pairing-labels-D2_BvwF2.js → pairing-labels-DxpfDscO.js} +1 -1
- package/dist/{pairing-store-bHxLRHu0.js → pairing-store-D5pH_THY.js} +1 -1
- package/dist/{pi-embedded-helpers-DWaCX4-U.js → pi-embedded-helpers-DiUtuQVi.js} +1 -1
- package/dist/{pi-embedded-helpers-CyocH3Nm.js → pi-embedded-helpers-UcI7GOJy.js} +2 -2
- package/dist/{pi-embedded-helpers-D5dTF-JC.js → pi-embedded-helpers-sNJhkxlO.js} +6 -6
- package/dist/{pi-tools.policy-BaCezaC3.js → pi-tools.policy-SsvnrL9o.js} +1 -1
- package/dist/{plugin-auto-enable-n4uLpFqu.js → plugin-auto-enable-Ckty7RH7.js} +2 -2
- package/dist/plugin-sdk/config/types.gateway.d.ts +2 -0
- package/dist/plugin-sdk/config/zod-schema.d.ts +1 -0
- package/dist/plugin-sdk/index.js +9 -8
- package/dist/{plugins-Z4YBdivb.js → plugins-Czjx5qei.js} +1 -1
- package/dist/{plugins-cli-Dqgo10-5.js → plugins-cli-B91z-ne_.js} +30 -30
- package/dist/{plugins-cli-bGrxvSKA.js → plugins-cli-DSiFUM2-.js} +14 -14
- package/dist/{ports-Bb3d3ttB.js → ports-B9ymx6GD.js} +1 -1
- package/dist/{program-BFj4K9CK.js → program-DkSPq75D.js} +58 -58
- package/dist/{pw-ai-BuTaDE6_.js → pw-ai-DzgG6D7d.js} +4 -4
- package/dist/{qmd-manager-C572raWY.js → qmd-manager-DUyjTVat.js} +15 -15
- package/dist/{register.subclis-OPhehcB_.js → register.subclis-CpNxblG5.js} +28 -28
- package/dist/{reply-CSzRmu_L.js → reply-rXytdF-s.js} +15 -15
- package/dist/{routes-TZ8X7uIF.js → routes-CKUJ66ZU.js} +1 -1
- package/dist/{routes-CF1YY3lZ.js → routes-qjmJrGBZ.js} +17 -17
- package/dist/{rpc-c3Ouvj9Z.js → rpc-C2BJ88B0.js} +1 -1
- package/dist/{rpc-DGylg8mL.js → rpc-CyliR4Jb.js} +1 -1
- package/dist/{run-main-Dg96nRaw.js → run-main-CTkDjBWt.js} +60 -60
- package/dist/{runner-C5-Hm63Y.js → runner-BSN7ndXQ.js} +30 -30
- package/dist/{runner-BAUJcuKH.js → runner-CkMvY-DA.js} +4 -4
- package/dist/{sandbox-BHhoHYtJ.js → sandbox-BlIjYgKj.js} +21 -21
- package/dist/{sandbox-cli-DfdVUMFD.js → sandbox-cli-CWjQ3CJV.js} +10 -10
- package/dist/{sandbox-cli-RTstaaC3.js → sandbox-cli-DPB_kidh.js} +3 -3
- package/dist/{sandbox-pyqhXr6S.js → sandbox-wOHQvch6.js} +2 -2
- package/dist/{security-cli-D2mmpAPT.js → security-cli-BSD9knoc.js} +21 -21
- package/dist/{security-cli-DmfFNrJw.js → security-cli-Bl7bR09E.js} +6 -6
- package/dist/{server-context-C-e92YdU.js → server-context-Bdeie10d.js} +4 -4
- package/dist/{server-node-events-COzAXYlM.js → server-node-events-BVks1cSg.js} +27 -27
- package/dist/{server-node-events-DwZUN91W.js → server-node-events-C9a8KO91.js} +15 -15
- package/dist/{service-Dn0w6vyS.js → service-DV05Mtg_.js} +17 -17
- package/dist/{service-audit-DRBHt3x1.js → service-audit-BtmGCivu.js} +1 -1
- package/dist/{service-audit-C_-BuSvV.js → service-audit-Cl2xpTw4.js} +13 -13
- package/dist/{shared-Dj0q68ab.js → shared-B_UA5GEy.js} +1 -1
- package/dist/{shared-B9OcWc8N.js → shared-D6pQLf6V.js} +1 -1
- package/dist/{skill-scanner-DtMxigBM.js → skill-scanner-BAxRMq-1.js} +5 -5
- package/dist/{skills-CVrsB4OF.js → skills-CCunBWnn.js} +1 -1
- package/dist/{skills-cli-drDlowxe.js → skills-cli-BKquUMQx.js} +1 -1
- package/dist/{skills-cli-CRgYzXMN.js → skills-cli-BZL5JE0I.js} +5 -5
- package/dist/{skills-status-DGIlZeAs.js → skills-status-C7vawdcf.js} +1 -1
- package/dist/{sqlite-BB-vJGj5.js → sqlite-DKK1V89f.js} +8 -8
- package/dist/{status-BRGUygXg.js → status-B1SQ-Yil.js} +2 -2
- package/dist/{status-CgvVkMyU.js → status-CMnSLP_j.js} +3 -3
- package/dist/{status-es24M0Jr.js → status-DqK2dG7C.js} +31 -31
- package/dist/{system-cli-C0HBS0Cm.js → system-cli-BlhAVepT.js} +3 -3
- package/dist/{system-cli-CrE0JntR.js → system-cli-D2toyIFb.js} +5 -5
- package/dist/{systemd-DRXkc2Kt.js → systemd-DQvm8tRB.js} +5 -5
- package/dist/{systemd-linger-BqR57bHu.js → systemd-linger-DcXZ2d0V.js} +1 -1
- package/dist/{tui-BU61z7-z.js → tui-BphTCmkN.js} +4 -4
- package/dist/{tui-DXZ80a7e.js → tui-DmyiEmq0.js} +5 -5
- package/dist/{tui-cli-BZhAicR8.js → tui-cli-BcCgFZAK.js} +7 -7
- package/dist/{tui-cli-CZgGMoZk.js → tui-cli-DEaetRTq.js} +14 -14
- package/dist/{update-DoCn70aq.js → update-BhfB1gW0.js} +3 -3
- package/dist/{update-cli-BlJB9QXz.js → update-cli-CXU0eiM5.js} +53 -53
- package/dist/{update-cli-DkVUnBFv.js → update-cli-DMnkb0sT.js} +21 -21
- package/dist/{update-runner-BVf31lJR.js → update-runner-C3M37OWx.js} +5 -5
- package/dist/{update-runner-Dg3fAwSp.js → update-runner-D8AUbg1Q.js} +25 -25
- package/dist/{webhooks-cli-BOljLMnw.js → webhooks-cli-DePWpBxb.js} +5 -5
- package/dist/{webhooks-cli-Bx2JxmxF.js → webhooks-cli-X2yUmhNI.js} +1 -1
- package/dist/{wsl-B7iFauUn.js → wsl-CGTJDuGq.js} +3 -3
- package/package.json +1 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import path from "node:path";
|
|
2
2
|
import fs from "node:fs";
|
|
3
|
-
import
|
|
3
|
+
import fs$1 from "node:fs/promises";
|
|
4
4
|
import { fileURLToPath } from "node:url";
|
|
5
5
|
|
|
6
6
|
//#region src/infra/SKYKOI-root.ts
|
|
7
7
|
const CORE_PACKAGE_NAMES = new Set(["skykoi"]);
|
|
8
8
|
async function readPackageName(dir) {
|
|
9
9
|
try {
|
|
10
|
-
const raw = await
|
|
10
|
+
const raw = await fs$1.readFile(path.join(dir, "package.json"), "utf-8");
|
|
11
11
|
const parsed = JSON.parse(raw);
|
|
12
12
|
return typeof parsed.name === "string" ? parsed.name : null;
|
|
13
13
|
} catch {
|
|
@@ -3,7 +3,7 @@ import { c as normalizeAccountId, t as DEFAULT_ACCOUNT_ID } from "./session-key-
|
|
|
3
3
|
import { l as jidToE164, m as resolveUserPath } from "./utils-BMYqLzNy.js";
|
|
4
4
|
import path from "node:path";
|
|
5
5
|
import fs from "node:fs";
|
|
6
|
-
import
|
|
6
|
+
import fs$1 from "node:fs/promises";
|
|
7
7
|
|
|
8
8
|
//#region src/web/auth-store.ts
|
|
9
9
|
function resolveDefaultWebAuthDir() {
|
|
@@ -56,14 +56,14 @@ async function webAuthExists(authDir = resolveDefaultWebAuthDir()) {
|
|
|
56
56
|
maybeRestoreCredsFromBackup(resolvedAuthDir);
|
|
57
57
|
const credsPath = resolveWebCredsPath(resolvedAuthDir);
|
|
58
58
|
try {
|
|
59
|
-
await
|
|
59
|
+
await fs$1.access(resolvedAuthDir);
|
|
60
60
|
} catch {
|
|
61
61
|
return false;
|
|
62
62
|
}
|
|
63
63
|
try {
|
|
64
|
-
const stats = await
|
|
64
|
+
const stats = await fs$1.stat(credsPath);
|
|
65
65
|
if (!stats.isFile() || stats.size <= 1) return false;
|
|
66
|
-
const raw = await
|
|
66
|
+
const raw = await fs$1.readFile(credsPath, "utf-8");
|
|
67
67
|
JSON.parse(raw);
|
|
68
68
|
return true;
|
|
69
69
|
} catch {
|
|
@@ -71,7 +71,7 @@ async function webAuthExists(authDir = resolveDefaultWebAuthDir()) {
|
|
|
71
71
|
}
|
|
72
72
|
}
|
|
73
73
|
async function clearLegacyBaileysAuthState(authDir) {
|
|
74
|
-
const entries = await
|
|
74
|
+
const entries = await fs$1.readdir(authDir, { withFileTypes: true });
|
|
75
75
|
const shouldDelete = (name) => {
|
|
76
76
|
if (name === "oauth.json") return false;
|
|
77
77
|
if (name === "creds.json" || name === "creds.json.bak") return true;
|
|
@@ -81,7 +81,7 @@ async function clearLegacyBaileysAuthState(authDir) {
|
|
|
81
81
|
await Promise.all(entries.map(async (entry) => {
|
|
82
82
|
if (!entry.isFile()) return;
|
|
83
83
|
if (!shouldDelete(entry.name)) return;
|
|
84
|
-
await
|
|
84
|
+
await fs$1.rm(path.join(authDir, entry.name), { force: true });
|
|
85
85
|
}));
|
|
86
86
|
}
|
|
87
87
|
async function logoutWeb(params) {
|
|
@@ -92,7 +92,7 @@ async function logoutWeb(params) {
|
|
|
92
92
|
return false;
|
|
93
93
|
}
|
|
94
94
|
if (params.isLegacyAuthDir) await clearLegacyBaileysAuthState(resolvedAuthDir);
|
|
95
|
-
else await
|
|
95
|
+
else await fs$1.rm(resolvedAuthDir, {
|
|
96
96
|
recursive: true,
|
|
97
97
|
force: true
|
|
98
98
|
});
|
|
@@ -7,11 +7,11 @@ import "./model-selection-BVecmGTV.js";
|
|
|
7
7
|
import "./boolean-B8-BqKGQ.js";
|
|
8
8
|
import "./env-CuKWe8kv.js";
|
|
9
9
|
import "./github-copilot-token-BZm0Gj7z.js";
|
|
10
|
-
import { i as loadConfig, j as VERSION } from "./config-
|
|
10
|
+
import { i as loadConfig, j as VERSION } from "./config-nVdFpcsN.js";
|
|
11
11
|
import "./manifest-registry-BWwhsgX7.js";
|
|
12
12
|
import { h as GATEWAY_CLIENT_NAMES, m as GATEWAY_CLIENT_MODES } from "./message-channel-DHb3z4h2.js";
|
|
13
13
|
import { l as GatewayClient } from "./net-sP4-ayNL.js";
|
|
14
|
-
import { t as buildGatewayConnectionDetails } from "./call-
|
|
14
|
+
import { t as buildGatewayConnectionDetails } from "./call-DA_VivF7.js";
|
|
15
15
|
import { t as formatDocsLink } from "./links-BYUF0_Hp.js";
|
|
16
16
|
import "./tailscale-C9oNI3cv.js";
|
|
17
17
|
import { t as isMainModule } from "./is-main-B6kCyqsv.js";
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { k as theme, p as defaultRuntime } from "./entry.js";
|
|
2
|
-
import "./auth-profiles-
|
|
2
|
+
import "./auth-profiles-BJV-XXxt.js";
|
|
3
3
|
import "./utils-BMYqLzNy.js";
|
|
4
4
|
import "./exec-CUWUdKmp.js";
|
|
5
|
-
import "./agent-scope-
|
|
5
|
+
import "./agent-scope-C-oITVZT.js";
|
|
6
6
|
import "./github-copilot-token-D3BDUkS_.js";
|
|
7
|
-
import { i as loadConfig, j as VERSION } from "./config-
|
|
7
|
+
import { i as loadConfig, j as VERSION } from "./config-DxY4DsNc.js";
|
|
8
8
|
import "./manifest-registry-BwckFakx.js";
|
|
9
9
|
import { t as ensureSKYKOICliOnPath } from "./path-env-DKuROk9X.js";
|
|
10
10
|
import "./tailscale-DPwNB3iM.js";
|
|
11
11
|
import { t as GatewayClient } from "./client-CkUn7eWk.js";
|
|
12
12
|
import { i as resolveGatewayAuth } from "./auth-kOl4q1D7.js";
|
|
13
|
-
import { t as buildGatewayConnectionDetails } from "./call-
|
|
13
|
+
import { t as buildGatewayConnectionDetails } from "./call-BsO3DxiF.js";
|
|
14
14
|
import { h as GATEWAY_CLIENT_NAMES, m as GATEWAY_CLIENT_MODES } from "./message-channel-6KBhOx_o.js";
|
|
15
15
|
import { t as isMainModule } from "./is-main-DopiqU5A.js";
|
|
16
16
|
import { t as formatDocsLink } from "./links-Br7nIvtU.js";
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { $ as DEFAULT_CHAT_CHANNEL, p as defaultRuntime } from "./entry.js";
|
|
2
|
-
import { C as buildAllowedModelSet, D as isCliProvider, L as resolveThinkingDefault, N as resolveConfiguredModelRef, O as modelKey, _ as ensureAuthProfileStore, bt as DEFAULT_PROVIDER, vt as DEFAULT_CONTEXT_TOKENS, yt as DEFAULT_MODEL } from "./auth-profiles-
|
|
2
|
+
import { C as buildAllowedModelSet, D as isCliProvider, L as resolveThinkingDefault, N as resolveConfiguredModelRef, O as modelKey, _ as ensureAuthProfileStore, bt as DEFAULT_PROVIDER, vt as DEFAULT_CONTEXT_TOKENS, yt as DEFAULT_MODEL } from "./auth-profiles-BJV-XXxt.js";
|
|
3
3
|
import { t as formatCliCommand } from "./command-format-B5jjY9oQ.js";
|
|
4
4
|
import { d as resolveAgentIdFromSessionKey, l as normalizeAgentId, u as normalizeMainKey } from "./session-key-BmNnF5dG.js";
|
|
5
|
-
import { a as resolveAgentModelPrimary, i as resolveAgentModelFallbacksOverride, o as resolveAgentSkillsFilter, r as resolveAgentDir, s as resolveAgentWorkspaceDir, t as listAgentIds, x as ensureAgentWorkspace } from "./agent-scope-
|
|
6
|
-
import { i as loadConfig } from "./config-
|
|
5
|
+
import { a as resolveAgentModelPrimary, i as resolveAgentModelFallbacksOverride, o as resolveAgentSkillsFilter, r as resolveAgentDir, s as resolveAgentWorkspaceDir, t as listAgentIds, x as ensureAgentWorkspace } from "./agent-scope-C-oITVZT.js";
|
|
6
|
+
import { i as loadConfig } from "./config-DxY4DsNc.js";
|
|
7
7
|
import { a as isInternalMessageChannel, d as resolveMessageChannel, i as isGatewayMessageChannel, l as normalizeMessageChannel, n as isDeliverableMessageChannel, t as INTERNAL_MESSAGE_CHANNEL } from "./message-channel-6KBhOx_o.js";
|
|
8
|
-
import { r as normalizeChannelId, t as getChannelPlugin } from "./plugins-
|
|
9
|
-
import { Bt as clearAgentRunContext, Dt as runEmbeddedPiAgent, H as getCliSessionId, Jt as applyModelOverrideToSessionEntry, K as resolveSendPolicy, Kt as AGENT_LANE_NESTED, Tn as runWithModelFallback, U as setCliSessionId, Vt as emitAgentEvent, W as runCliAgent, Wt as registerAgentRunContext, bn as resolveOutboundTarget, ct as clearSessionAuthProfileOverride, dn as lookupContextTokens, lt as applyVerboseOverride, ot as getSkillsSnapshotVersion, q as getRemoteSkillEligibility, qt as loadModelCatalog, xn as resolveSessionDeliveryTarget, zt as resolveAgentTimeoutMs } from "./loader-
|
|
8
|
+
import { r as normalizeChannelId, t as getChannelPlugin } from "./plugins-Czjx5qei.js";
|
|
9
|
+
import { Bt as clearAgentRunContext, Dt as runEmbeddedPiAgent, H as getCliSessionId, Jt as applyModelOverrideToSessionEntry, K as resolveSendPolicy, Kt as AGENT_LANE_NESTED, Tn as runWithModelFallback, U as setCliSessionId, Vt as emitAgentEvent, W as runCliAgent, Wt as registerAgentRunContext, bn as resolveOutboundTarget, ct as clearSessionAuthProfileOverride, dn as lookupContextTokens, lt as applyVerboseOverride, ot as getSkillsSnapshotVersion, q as getRemoteSkillEligibility, qt as loadModelCatalog, xn as resolveSessionDeliveryTarget, zt as resolveAgentTimeoutMs } from "./loader-DJZg0qBH.js";
|
|
10
10
|
import { n as resolveSessionFilePath, o as resolveStorePath } from "./paths-DPLOvGLU.js";
|
|
11
|
-
import { B as normalizeThinkLevel, F as formatXHighModelHint, H as normalizeVerboseLevel, P as formatThinkingLevels, W as supportsXHighThinking } from "./pi-embedded-helpers-
|
|
12
|
-
import { a as normalizeOutboundPayloadsForJson, i as normalizeOutboundPayloads, r as formatOutboundPayloadLog, t as deliverOutboundPayloads } from "./deliver-
|
|
13
|
-
import { A as resolveSessionResetType, D as evaluateSessionFreshness, E as resolveSessionKey, F as resolveExplicitAgentSessionKey, O as resolveChannelResetConfig, T as normalizeAccountId, d as loadSessionStore, g as updateSessionStore, k as resolveSessionResetPolicy } from "./sandbox-
|
|
14
|
-
import { r as buildWorkspaceSkillSnapshot } from "./skills-
|
|
11
|
+
import { B as normalizeThinkLevel, F as formatXHighModelHint, H as normalizeVerboseLevel, P as formatThinkingLevels, W as supportsXHighThinking } from "./pi-embedded-helpers-sNJhkxlO.js";
|
|
12
|
+
import { a as normalizeOutboundPayloadsForJson, i as normalizeOutboundPayloads, r as formatOutboundPayloadLog, t as deliverOutboundPayloads } from "./deliver-5iHaga2j.js";
|
|
13
|
+
import { A as resolveSessionResetType, D as evaluateSessionFreshness, E as resolveSessionKey, F as resolveExplicitAgentSessionKey, O as resolveChannelResetConfig, T as normalizeAccountId, d as loadSessionStore, g as updateSessionStore, k as resolveSessionResetPolicy } from "./sandbox-BlIjYgKj.js";
|
|
14
|
+
import { r as buildWorkspaceSkillSnapshot } from "./skills-CCunBWnn.js";
|
|
15
15
|
import { l as hasNonzeroUsage } from "./session-cost-usage-Ceehob2Z.js";
|
|
16
|
-
import { t as createDefaultDeps } from "./deps-
|
|
16
|
+
import { t as createDefaultDeps } from "./deps-QpJPsy_z.js";
|
|
17
17
|
import crypto from "node:crypto";
|
|
18
18
|
|
|
19
19
|
//#region src/cli/outbound-send-deps.ts
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import { H as normalizeThinkLevel, I as formatThinkingLevels, K as supportsXHighThinking, L as formatXHighModelHint, W as normalizeVerboseLevel } from "./pi-embedded-helpers-
|
|
2
|
-
import { An as emitAgentEvent, Er as loadModelCatalog, I as runWithModelFallback, M as resolveSessionDeliveryTarget, Nn as registerAgentRunContext, On as AGENT_LANE_NESTED, Rt as getRemoteSkillEligibility, Vr as resolveAgentTimeoutMs, Zt as getSkillsSnapshotVersion, br as applyModelOverrideToSessionEntry, c as runEmbeddedPiAgent, i as runCliAgent, j as resolveOutboundTarget, kn as clearAgentRunContext, n as getCliSessionId, o as resolveSendPolicy, r as setCliSessionId, vr as lookupContextTokens, xr as applyVerboseOverride, yr as clearSessionAuthProfileOverride } from "./reply-
|
|
1
|
+
import { H as normalizeThinkLevel, I as formatThinkingLevels, K as supportsXHighThinking, L as formatXHighModelHint, W as normalizeVerboseLevel } from "./pi-embedded-helpers-UcI7GOJy.js";
|
|
2
|
+
import { An as emitAgentEvent, Er as loadModelCatalog, I as runWithModelFallback, M as resolveSessionDeliveryTarget, Nn as registerAgentRunContext, On as AGENT_LANE_NESTED, Rt as getRemoteSkillEligibility, Vr as resolveAgentTimeoutMs, Zt as getSkillsSnapshotVersion, br as applyModelOverrideToSessionEntry, c as runEmbeddedPiAgent, i as runCliAgent, j as resolveOutboundTarget, kn as clearAgentRunContext, n as getCliSessionId, o as resolveSendPolicy, r as setCliSessionId, vr as lookupContextTokens, xr as applyVerboseOverride, yr as clearSessionAuthProfileOverride } from "./reply-rXytdF-s.js";
|
|
3
3
|
import { d as resolveAgentIdFromSessionKey, l as normalizeAgentId, u as normalizeMainKey } from "./session-key-DrNCyvP1.js";
|
|
4
4
|
import { c as defaultRuntime, h as DEFAULT_CHAT_CHANNEL } from "./subsystem-B6KC_eUM.js";
|
|
5
5
|
import { a as resolveAgentModelPrimary, i as resolveAgentModelFallbacksOverride, o as resolveAgentSkillsFilter, r as resolveAgentDir, s as resolveAgentWorkspaceDir, t as listAgentIds, x as ensureAgentWorkspace } from "./agent-scope-DgrFnRZg.js";
|
|
6
6
|
import { Ct as DEFAULT_PROVIDER, St as DEFAULT_MODEL, a as isCliProvider, d as resolveConfiguredModelRef, h as resolveThinkingDefault, o as modelKey, ot as ensureAuthProfileStore, t as buildAllowedModelSet, xt as DEFAULT_CONTEXT_TOKENS } from "./model-selection-BVecmGTV.js";
|
|
7
7
|
import { t as formatCliCommand } from "./command-format-FMXZ1CPB.js";
|
|
8
|
-
import { i as loadConfig } from "./config-
|
|
8
|
+
import { i as loadConfig } from "./config-nVdFpcsN.js";
|
|
9
9
|
import { r as normalizeChannelId, t as getChannelPlugin } from "./plugins-Dy91ZCOv.js";
|
|
10
|
-
import { A as resolveSessionResetPolicy, D as resolveSessionKey, I as resolveExplicitAgentSessionKey, O as evaluateSessionFreshness, T as normalizeAccountId, d as loadSessionStore, g as updateSessionStore, j as resolveSessionResetType, k as resolveChannelResetConfig } from "./sandbox-
|
|
10
|
+
import { A as resolveSessionResetPolicy, D as resolveSessionKey, I as resolveExplicitAgentSessionKey, O as evaluateSessionFreshness, T as normalizeAccountId, d as loadSessionStore, g as updateSessionStore, j as resolveSessionResetType, k as resolveChannelResetConfig } from "./sandbox-wOHQvch6.js";
|
|
11
11
|
import { r as buildWorkspaceSkillSnapshot } from "./skills-CLfcjncu.js";
|
|
12
12
|
import { a as isInternalMessageChannel, d as resolveMessageChannel, i as isGatewayMessageChannel, l as normalizeMessageChannel, n as isDeliverableMessageChannel, t as INTERNAL_MESSAGE_CHANNEL } from "./message-channel-DHb3z4h2.js";
|
|
13
13
|
import { n as resolveSessionFilePath, o as resolveStorePath } from "./paths-BRP11_63.js";
|
|
14
|
-
import { a as normalizeOutboundPayloadsForJson, i as normalizeOutboundPayloads, r as formatOutboundPayloadLog, t as deliverOutboundPayloads } from "./deliver-
|
|
14
|
+
import { a as normalizeOutboundPayloadsForJson, i as normalizeOutboundPayloads, r as formatOutboundPayloadLog, t as deliverOutboundPayloads } from "./deliver-BQVz85YI.js";
|
|
15
15
|
import { l as hasNonzeroUsage } from "./session-cost-usage-BR5ASC0b.js";
|
|
16
|
-
import { t as createDefaultDeps } from "./deps-
|
|
16
|
+
import { t as createDefaultDeps } from "./deps-Bh3TqNB-.js";
|
|
17
17
|
import crypto from "node:crypto";
|
|
18
18
|
|
|
19
19
|
//#region src/cli/outbound-send-deps.ts
|
|
@@ -2,10 +2,10 @@ import { X as resolveStateDir } from "./entry.js";
|
|
|
2
2
|
import { _ as isSubagentSessionKey, l as normalizeAgentId, n as DEFAULT_AGENT_ID, v as parseAgentSessionKey } from "./session-key-BmNnF5dG.js";
|
|
3
3
|
import { m as resolveUserPath } from "./utils-BMYqLzNy.js";
|
|
4
4
|
import { t as runCommandWithTimeout } from "./exec-CUWUdKmp.js";
|
|
5
|
-
import { t as resolveSKYKOIPackageRoot } from "./SKYKOI-root-
|
|
5
|
+
import { t as resolveSKYKOIPackageRoot } from "./SKYKOI-root-B5HYTPZX.js";
|
|
6
6
|
import path from "node:path";
|
|
7
7
|
import os from "node:os";
|
|
8
|
-
import
|
|
8
|
+
import fs from "node:fs/promises";
|
|
9
9
|
import { fileURLToPath } from "node:url";
|
|
10
10
|
|
|
11
11
|
//#region src/agents/workspace-templates.ts
|
|
@@ -14,7 +14,7 @@ let cachedTemplateDir;
|
|
|
14
14
|
let resolvingTemplateDir;
|
|
15
15
|
async function pathExists(candidate) {
|
|
16
16
|
try {
|
|
17
|
-
await
|
|
17
|
+
await fs.access(candidate);
|
|
18
18
|
return true;
|
|
19
19
|
} catch {
|
|
20
20
|
return false;
|
|
@@ -81,14 +81,14 @@ async function loadTemplate(name) {
|
|
|
81
81
|
const templateDir = await resolveWorkspaceTemplateDir();
|
|
82
82
|
const templatePath = path.join(templateDir, name);
|
|
83
83
|
try {
|
|
84
|
-
return stripFrontMatter(await
|
|
84
|
+
return stripFrontMatter(await fs.readFile(templatePath, "utf-8"));
|
|
85
85
|
} catch {
|
|
86
86
|
throw new Error(`Missing workspace template: ${name} (${templatePath}). Ensure docs/reference/templates are packaged.`);
|
|
87
87
|
}
|
|
88
88
|
}
|
|
89
89
|
async function writeFileIfMissing(filePath, content) {
|
|
90
90
|
try {
|
|
91
|
-
await
|
|
91
|
+
await fs.writeFile(filePath, content, {
|
|
92
92
|
encoding: "utf-8",
|
|
93
93
|
flag: "wx"
|
|
94
94
|
});
|
|
@@ -98,7 +98,7 @@ async function writeFileIfMissing(filePath, content) {
|
|
|
98
98
|
}
|
|
99
99
|
async function hasGitRepo(dir) {
|
|
100
100
|
try {
|
|
101
|
-
await
|
|
101
|
+
await fs.stat(path.join(dir, ".git"));
|
|
102
102
|
return true;
|
|
103
103
|
} catch {
|
|
104
104
|
return false;
|
|
@@ -124,7 +124,7 @@ async function ensureGitRepo(dir, isBrandNewWorkspace) {
|
|
|
124
124
|
}
|
|
125
125
|
async function ensureAgentWorkspace(params) {
|
|
126
126
|
const dir = resolveUserPath(params?.dir?.trim() ? params.dir.trim() : DEFAULT_AGENT_WORKSPACE_DIR);
|
|
127
|
-
await
|
|
127
|
+
await fs.mkdir(dir, { recursive: true });
|
|
128
128
|
if (!params?.ensureBootstrapFiles) return { dir };
|
|
129
129
|
const agentsPath = path.join(dir, DEFAULT_AGENTS_FILENAME);
|
|
130
130
|
const soulPath = path.join(dir, DEFAULT_SOUL_FILENAME);
|
|
@@ -144,7 +144,7 @@ async function ensureAgentWorkspace(params) {
|
|
|
144
144
|
];
|
|
145
145
|
return (await Promise.all(paths.map(async (p) => {
|
|
146
146
|
try {
|
|
147
|
-
await
|
|
147
|
+
await fs.access(p);
|
|
148
148
|
return true;
|
|
149
149
|
} catch {
|
|
150
150
|
return false;
|
|
@@ -183,7 +183,7 @@ async function resolveMemoryBootstrapEntries(resolvedDir) {
|
|
|
183
183
|
for (const name of candidates) {
|
|
184
184
|
const filePath = path.join(resolvedDir, name);
|
|
185
185
|
try {
|
|
186
|
-
await
|
|
186
|
+
await fs.access(filePath);
|
|
187
187
|
entries.push({
|
|
188
188
|
name,
|
|
189
189
|
filePath
|
|
@@ -196,7 +196,7 @@ async function resolveMemoryBootstrapEntries(resolvedDir) {
|
|
|
196
196
|
for (const entry of entries) {
|
|
197
197
|
let key = entry.filePath;
|
|
198
198
|
try {
|
|
199
|
-
key = await
|
|
199
|
+
key = await fs.realpath(entry.filePath);
|
|
200
200
|
} catch {}
|
|
201
201
|
if (seen.has(key)) continue;
|
|
202
202
|
seen.add(key);
|
|
@@ -239,7 +239,7 @@ async function loadWorkspaceBootstrapFiles(dir) {
|
|
|
239
239
|
entries.push(...await resolveMemoryBootstrapEntries(resolvedDir));
|
|
240
240
|
const result = [];
|
|
241
241
|
for (const entry of entries) try {
|
|
242
|
-
const content = await
|
|
242
|
+
const content = await fs.readFile(entry.filePath, "utf-8");
|
|
243
243
|
result.push({
|
|
244
244
|
name: entry.name,
|
|
245
245
|
path: entry.filePath,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import path from "node:path";
|
|
2
|
-
import
|
|
2
|
+
import fs from "node:fs/promises";
|
|
3
3
|
import JSZip from "jszip";
|
|
4
4
|
import * as tar from "tar";
|
|
5
5
|
|
|
@@ -18,9 +18,9 @@ function resolveArchiveKind(filePath) {
|
|
|
18
18
|
async function resolvePackedRootDir(extractDir) {
|
|
19
19
|
const direct = path.join(extractDir, "package");
|
|
20
20
|
try {
|
|
21
|
-
if ((await
|
|
21
|
+
if ((await fs.stat(direct)).isDirectory()) return direct;
|
|
22
22
|
} catch {}
|
|
23
|
-
const dirs = (await
|
|
23
|
+
const dirs = (await fs.readdir(extractDir, { withFileTypes: true })).filter((entry) => entry.isDirectory()).map((entry) => entry.name);
|
|
24
24
|
if (dirs.length !== 1) throw new Error(`unexpected archive layout (dirs: ${dirs.join(", ")})`);
|
|
25
25
|
const onlyDir = dirs[0];
|
|
26
26
|
if (!onlyDir) throw new Error("unexpected archive layout (no package dir found)");
|
|
@@ -37,7 +37,7 @@ async function withTimeout(promise, timeoutMs, label) {
|
|
|
37
37
|
}
|
|
38
38
|
}
|
|
39
39
|
async function extractZip(params) {
|
|
40
|
-
const buffer = await
|
|
40
|
+
const buffer = await fs.readFile(params.archivePath);
|
|
41
41
|
const zip = await JSZip.loadAsync(buffer);
|
|
42
42
|
const entries = Object.values(zip.files);
|
|
43
43
|
for (const entry of entries) {
|
|
@@ -45,14 +45,14 @@ async function extractZip(params) {
|
|
|
45
45
|
if (!entryPath || entryPath.endsWith("/")) {
|
|
46
46
|
const dirPath = path.resolve(params.destDir, entryPath);
|
|
47
47
|
if (!dirPath.startsWith(params.destDir)) throw new Error(`zip entry escapes destination: ${entry.name}`);
|
|
48
|
-
await
|
|
48
|
+
await fs.mkdir(dirPath, { recursive: true });
|
|
49
49
|
continue;
|
|
50
50
|
}
|
|
51
51
|
const outPath = path.resolve(params.destDir, entryPath);
|
|
52
52
|
if (!outPath.startsWith(params.destDir)) throw new Error(`zip entry escapes destination: ${entry.name}`);
|
|
53
|
-
await
|
|
53
|
+
await fs.mkdir(path.dirname(outPath), { recursive: true });
|
|
54
54
|
const data = await entry.async("nodebuffer");
|
|
55
|
-
await
|
|
55
|
+
await fs.writeFile(outPath, data);
|
|
56
56
|
}
|
|
57
57
|
}
|
|
58
58
|
async function extractArchive(params) {
|
|
@@ -70,14 +70,14 @@ async function extractArchive(params) {
|
|
|
70
70
|
}
|
|
71
71
|
async function fileExists(filePath) {
|
|
72
72
|
try {
|
|
73
|
-
await
|
|
73
|
+
await fs.stat(filePath);
|
|
74
74
|
return true;
|
|
75
75
|
} catch {
|
|
76
76
|
return false;
|
|
77
77
|
}
|
|
78
78
|
}
|
|
79
79
|
async function readJsonFile(filePath) {
|
|
80
|
-
const raw = await
|
|
80
|
+
const raw = await fs.readFile(filePath, "utf-8");
|
|
81
81
|
return JSON.parse(raw);
|
|
82
82
|
}
|
|
83
83
|
|
|
@@ -3,17 +3,17 @@ import { l as normalizeAgentId } from "./session-key-DrNCyvP1.js";
|
|
|
3
3
|
import { n as runExec } from "./exec-B_35B71R.js";
|
|
4
4
|
import { c as resolveDefaultAgentId, s as resolveAgentWorkspaceDir } from "./agent-scope-DgrFnRZg.js";
|
|
5
5
|
import { t as formatCliCommand } from "./command-format-FMXZ1CPB.js";
|
|
6
|
-
import { D as MAX_INCLUDE_DEPTH, E as INCLUDE_KEY, r as createConfigIO } from "./config-
|
|
6
|
+
import { D as MAX_INCLUDE_DEPTH, E as INCLUDE_KEY, r as createConfigIO } from "./config-nVdFpcsN.js";
|
|
7
7
|
import { a as MANIFEST_KEY } from "./manifest-registry-BWwhsgX7.js";
|
|
8
8
|
import { n as listChannelPlugins } from "./plugins-Dy91ZCOv.js";
|
|
9
|
-
import { $ as resolveSandboxToolPolicyForAgent, Z as resolveSandboxConfigForAgent, ot as resolveToolProfilePolicy } from "./sandbox-
|
|
9
|
+
import { $ as resolveSandboxToolPolicyForAgent, Z as resolveSandboxConfigForAgent, ot as resolveToolProfilePolicy } from "./sandbox-wOHQvch6.js";
|
|
10
10
|
import { i as loadWorkspaceSkillEntries } from "./skills-CLfcjncu.js";
|
|
11
11
|
import { a as resolveProfile, i as resolveBrowserConfig } from "./server-context-B7H-KlhV.js";
|
|
12
12
|
import { h as GATEWAY_CLIENT_NAMES, m as GATEWAY_CLIENT_MODES } from "./message-channel-DHb3z4h2.js";
|
|
13
13
|
import { l as GatewayClient } from "./net-sP4-ayNL.js";
|
|
14
|
-
import { t as buildGatewayConnectionDetails } from "./call-
|
|
14
|
+
import { t as buildGatewayConnectionDetails } from "./call-DA_VivF7.js";
|
|
15
15
|
import { i as readChannelAllowFromStore } from "./pairing-store-DRbuKDlg.js";
|
|
16
|
-
import { c as resolveNativeSkillsEnabled, n as isToolAllowedByPolicies, s as resolveNativeCommandsEnabled } from "./pi-tools.policy-
|
|
16
|
+
import { c as resolveNativeSkillsEnabled, n as isToolAllowedByPolicies, s as resolveNativeCommandsEnabled } from "./pi-tools.policy-SsvnrL9o.js";
|
|
17
17
|
import { t as resolveChannelDefaultAccountId } from "./helpers-yjIEMzi8.js";
|
|
18
18
|
import { t as scanDirectoryWithSummary } from "./skill-scanner-BoGjHXUZ.js";
|
|
19
19
|
import { i as resolveGatewayAuth } from "./auth-DSrYkGU-.js";
|
|
@@ -2,25 +2,25 @@ import { B as resolveConfigPath, J as resolveOAuthDir, X as resolveStateDir } fr
|
|
|
2
2
|
import { t as formatCliCommand } from "./command-format-B5jjY9oQ.js";
|
|
3
3
|
import { l as normalizeAgentId } from "./session-key-BmNnF5dG.js";
|
|
4
4
|
import { n as runExec } from "./exec-CUWUdKmp.js";
|
|
5
|
-
import { c as resolveDefaultAgentId, s as resolveAgentWorkspaceDir } from "./agent-scope-
|
|
6
|
-
import { D as MAX_INCLUDE_DEPTH, E as INCLUDE_KEY, r as createConfigIO } from "./config-
|
|
5
|
+
import { c as resolveDefaultAgentId, s as resolveAgentWorkspaceDir } from "./agent-scope-C-oITVZT.js";
|
|
6
|
+
import { D as MAX_INCLUDE_DEPTH, E as INCLUDE_KEY, r as createConfigIO } from "./config-DxY4DsNc.js";
|
|
7
7
|
import { a as MANIFEST_KEY } from "./manifest-registry-BwckFakx.js";
|
|
8
|
-
import { a as resolveBrowserConfig, o as resolveProfile } from "./server-context-
|
|
8
|
+
import { a as resolveBrowserConfig, o as resolveProfile } from "./server-context-Bdeie10d.js";
|
|
9
9
|
import { t as GatewayClient } from "./client-CkUn7eWk.js";
|
|
10
10
|
import { i as resolveGatewayAuth } from "./auth-kOl4q1D7.js";
|
|
11
|
-
import { t as buildGatewayConnectionDetails } from "./call-
|
|
11
|
+
import { t as buildGatewayConnectionDetails } from "./call-BsO3DxiF.js";
|
|
12
12
|
import { h as GATEWAY_CLIENT_NAMES, m as GATEWAY_CLIENT_MODES } from "./message-channel-6KBhOx_o.js";
|
|
13
|
-
import { n as listChannelPlugins } from "./plugins-
|
|
13
|
+
import { n as listChannelPlugins } from "./plugins-Czjx5qei.js";
|
|
14
14
|
import { t as resolveChannelDefaultAccountId } from "./helpers-BToWq-9U.js";
|
|
15
|
-
import { t as scanDirectoryWithSummary } from "./skill-scanner-
|
|
16
|
-
import { G as resolveSandboxToolPolicyForAgent, Q as resolveToolProfilePolicy, U as resolveSandboxConfigForAgent } from "./sandbox-
|
|
17
|
-
import { i as loadWorkspaceSkillEntries } from "./skills-
|
|
18
|
-
import { a as isToolAllowedByPolicies, n as resolveNativeCommandsEnabled, r as resolveNativeSkillsEnabled } from "./commands-
|
|
19
|
-
import { i as readChannelAllowFromStore } from "./pairing-store-
|
|
15
|
+
import { t as scanDirectoryWithSummary } from "./skill-scanner-BAxRMq-1.js";
|
|
16
|
+
import { G as resolveSandboxToolPolicyForAgent, Q as resolveToolProfilePolicy, U as resolveSandboxConfigForAgent } from "./sandbox-BlIjYgKj.js";
|
|
17
|
+
import { i as loadWorkspaceSkillEntries } from "./skills-CCunBWnn.js";
|
|
18
|
+
import { a as isToolAllowedByPolicies, n as resolveNativeCommandsEnabled, r as resolveNativeSkillsEnabled } from "./commands-C9c-lr8S.js";
|
|
19
|
+
import { i as readChannelAllowFromStore } from "./pairing-store-D5pH_THY.js";
|
|
20
20
|
import path from "node:path";
|
|
21
21
|
import os from "node:os";
|
|
22
22
|
import JSON5 from "json5";
|
|
23
|
-
import
|
|
23
|
+
import fs from "node:fs/promises";
|
|
24
24
|
import { randomUUID } from "node:crypto";
|
|
25
25
|
|
|
26
26
|
//#region src/gateway/probe.ts
|
|
@@ -275,7 +275,7 @@ function createIcaclsResetCommand(targetPath, opts) {
|
|
|
275
275
|
//#region src/security/audit-fs.ts
|
|
276
276
|
async function safeStat(targetPath) {
|
|
277
277
|
try {
|
|
278
|
-
const lst = await
|
|
278
|
+
const lst = await fs.lstat(targetPath);
|
|
279
279
|
return {
|
|
280
280
|
ok: true,
|
|
281
281
|
isSymlink: lst.isSymbolicLink(),
|
|
@@ -750,7 +750,7 @@ async function collectPluginsTrustFindings(params) {
|
|
|
750
750
|
const extensionsDir = path.join(params.stateDir, "extensions");
|
|
751
751
|
const st = await safeStat(extensionsDir);
|
|
752
752
|
if (!st.ok || !st.isDir) return findings;
|
|
753
|
-
const pluginDirs = (await
|
|
753
|
+
const pluginDirs = (await fs.readdir(extensionsDir, { withFileTypes: true }).catch(() => [])).filter((e) => e.isDirectory()).map((e) => e.name).filter(Boolean);
|
|
754
754
|
if (pluginDirs.length === 0) return findings;
|
|
755
755
|
const allow = params.cfg.plugins?.allow;
|
|
756
756
|
if (!(Array.isArray(allow) && allow.length > 0)) {
|
|
@@ -815,7 +815,7 @@ async function collectIncludePathsRecursive(params) {
|
|
|
815
815
|
if (visited.has(resolved)) continue;
|
|
816
816
|
visited.add(resolved);
|
|
817
817
|
result.push(resolved);
|
|
818
|
-
const rawText = await
|
|
818
|
+
const rawText = await fs.readFile(resolved, "utf-8").catch(() => null);
|
|
819
819
|
if (!rawText) continue;
|
|
820
820
|
const nestedParsed = (() => {
|
|
821
821
|
try {
|
|
@@ -1060,7 +1060,7 @@ function extensionUsesSkippedScannerPath(entry) {
|
|
|
1060
1060
|
}
|
|
1061
1061
|
async function readPluginManifestExtensions(pluginPath) {
|
|
1062
1062
|
const manifestPath = path.join(pluginPath, "package.json");
|
|
1063
|
-
const raw = await
|
|
1063
|
+
const raw = await fs.readFile(manifestPath, "utf-8").catch(() => "");
|
|
1064
1064
|
if (!raw.trim()) return [];
|
|
1065
1065
|
const extensions = JSON.parse(raw)?.[MANIFEST_KEY]?.extensions;
|
|
1066
1066
|
if (!Array.isArray(extensions)) return [];
|
|
@@ -1087,7 +1087,7 @@ async function collectPluginsCodeSafetyFindings(params) {
|
|
|
1087
1087
|
const extensionsDir = path.join(params.stateDir, "extensions");
|
|
1088
1088
|
const st = await safeStat(extensionsDir);
|
|
1089
1089
|
if (!st.ok || !st.isDir) return findings;
|
|
1090
|
-
const pluginDirs = (await
|
|
1090
|
+
const pluginDirs = (await fs.readdir(extensionsDir, { withFileTypes: true }).catch((err) => {
|
|
1091
1091
|
findings.push({
|
|
1092
1092
|
checkId: "plugins.code_safety.scan_failed",
|
|
1093
1093
|
severity: "warn",
|
|
@@ -3,7 +3,7 @@ import { X as resolveStateDir, Y as resolveOAuthPath, n as isTruthyEnvValue, o a
|
|
|
3
3
|
import { t as formatCliCommand } from "./command-format-B5jjY9oQ.js";
|
|
4
4
|
import { n as DEFAULT_AGENT_ID } from "./session-key-BmNnF5dG.js";
|
|
5
5
|
import { m as resolveUserPath } from "./utils-BMYqLzNy.js";
|
|
6
|
-
import { a as resolveAgentModelPrimary } from "./agent-scope-
|
|
6
|
+
import { a as resolveAgentModelPrimary } from "./agent-scope-C-oITVZT.js";
|
|
7
7
|
import { a as saveJsonFile, i as loadJsonFile, r as resolveCopilotApiToken, t as DEFAULT_COPILOT_API_BASE_URL } from "./github-copilot-token-D3BDUkS_.js";
|
|
8
8
|
import { execFileSync, execSync } from "node:child_process";
|
|
9
9
|
import path from "node:path";
|
package/dist/build-info.json
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { B as resolveConfigPath, W as resolveGatewayPort, X as resolveStateDir } from "./entry.js";
|
|
2
2
|
import { h as shortenHomeInString, m as resolveUserPath, o as ensureDir, t as CONFIG_DIR } from "./utils-BMYqLzNy.js";
|
|
3
|
-
import { i as loadConfig } from "./config-
|
|
3
|
+
import { i as loadConfig } from "./config-DxY4DsNc.js";
|
|
4
4
|
import { t as pickPrimaryTailnetIPv4 } from "./tailnet-DdlcUdSm.js";
|
|
5
5
|
import { Et as PROTOCOL_VERSION, Mt as normalizeFingerprint, Pt as loadOrCreateDeviceIdentity, Vt as pickPrimaryLanIPv4, t as GatewayClient } from "./client-CkUn7eWk.js";
|
|
6
6
|
import { h as GATEWAY_CLIENT_NAMES, m as GATEWAY_CLIENT_MODES } from "./message-channel-6KBhOx_o.js";
|
|
7
7
|
import { execFile } from "node:child_process";
|
|
8
8
|
import path from "node:path";
|
|
9
9
|
import { promisify } from "node:util";
|
|
10
|
-
import
|
|
10
|
+
import fs from "node:fs/promises";
|
|
11
11
|
import { X509Certificate, randomUUID } from "node:crypto";
|
|
12
12
|
|
|
13
13
|
//#region src/infra/tls/gateway.ts
|
|
14
14
|
const execFileAsync = promisify(execFile);
|
|
15
15
|
async function fileExists(filePath) {
|
|
16
16
|
try {
|
|
17
|
-
await
|
|
17
|
+
await fs.access(filePath);
|
|
18
18
|
return true;
|
|
19
19
|
} catch {
|
|
20
20
|
return false;
|
|
@@ -41,8 +41,8 @@ async function generateSelfSignedCert(params) {
|
|
|
41
41
|
"-subj",
|
|
42
42
|
"/CN=SKYKOI-gateway"
|
|
43
43
|
]);
|
|
44
|
-
await
|
|
45
|
-
await
|
|
44
|
+
await fs.chmod(params.keyPath, 384).catch(() => {});
|
|
45
|
+
await fs.chmod(params.certPath, 384).catch(() => {});
|
|
46
46
|
params.log?.info?.(`gateway tls: generated self-signed cert at ${shortenHomeInString(params.certPath)}`);
|
|
47
47
|
}
|
|
48
48
|
async function loadGatewayTlsRuntime(cfg, log) {
|
|
@@ -80,9 +80,9 @@ async function loadGatewayTlsRuntime(cfg, log) {
|
|
|
80
80
|
error: "gateway tls: cert/key missing"
|
|
81
81
|
};
|
|
82
82
|
try {
|
|
83
|
-
const cert = await
|
|
84
|
-
const key = await
|
|
85
|
-
const ca = caPath ? await
|
|
83
|
+
const cert = await fs.readFile(certPath, "utf8");
|
|
84
|
+
const key = await fs.readFile(keyPath, "utf8");
|
|
85
|
+
const ca = caPath ? await fs.readFile(caPath, "utf8") : void 0;
|
|
86
86
|
const fingerprintSha256 = normalizeFingerprint(new X509Certificate(cert).fingerprint256 ?? "");
|
|
87
87
|
if (!fingerprintSha256) return {
|
|
88
88
|
enabled: false,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { g as resolveStateDir, o as resolveConfigPath, u as resolveGatewayPort } from "./paths-BP5k1v-m.js";
|
|
2
2
|
import { g as shortenHomeInString, h as resolveUserPath, s as ensureDir, t as CONFIG_DIR } from "./utils-CV3CeN0V.js";
|
|
3
|
-
import { i as loadConfig } from "./config-
|
|
3
|
+
import { i as loadConfig } from "./config-nVdFpcsN.js";
|
|
4
4
|
import { h as GATEWAY_CLIENT_NAMES, m as GATEWAY_CLIENT_MODES } from "./message-channel-DHb3z4h2.js";
|
|
5
5
|
import { Bt as normalizeFingerprint, Ht as loadOrCreateDeviceIdentity, Pt as PROTOCOL_VERSION, a as pickPrimaryLanIPv4, l as GatewayClient } from "./net-sP4-ayNL.js";
|
|
6
6
|
import { t as pickPrimaryTailnetIPv4 } from "./tailnet-DLDGNuH2.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
a31fb385bdc83f5ef0206dad356115555fcf5a22e549571a77759d01d0fb50c4
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Q as CHAT_CHANNEL_ORDER, n as isTruthyEnvValue } from "./entry.js";
|
|
2
|
-
import { i as listChannelPluginCatalogEntries } from "./plugin-auto-enable-
|
|
3
|
-
import { n as listChannelPlugins } from "./plugins-
|
|
4
|
-
import { n as ensurePluginRegistryLoaded } from "./command-options-
|
|
2
|
+
import { i as listChannelPluginCatalogEntries } from "./plugin-auto-enable-Ckty7RH7.js";
|
|
3
|
+
import { n as listChannelPlugins } from "./plugins-Czjx5qei.js";
|
|
4
|
+
import { n as ensurePluginRegistryLoaded } from "./command-options-CebL-fVk.js";
|
|
5
5
|
|
|
6
6
|
//#region src/cli/channel-options.ts
|
|
7
7
|
function dedupe(values) {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { lt as loadSKYKOIPlugins } from "./reply-
|
|
1
|
+
import { lt as loadSKYKOIPlugins } from "./reply-rXytdF-s.js";
|
|
2
2
|
import { m as CHAT_CHANNEL_ORDER, t as createSubsystemLogger } from "./subsystem-B6KC_eUM.js";
|
|
3
3
|
import { c as resolveDefaultAgentId, s as resolveAgentWorkspaceDir } from "./agent-scope-DgrFnRZg.js";
|
|
4
4
|
import { t as isTruthyEnvValue } from "./env-CuKWe8kv.js";
|
|
5
|
-
import { i as loadConfig } from "./config-
|
|
5
|
+
import { i as loadConfig } from "./config-nVdFpcsN.js";
|
|
6
6
|
import { n as listChannelPlugins } from "./plugins-Dy91ZCOv.js";
|
|
7
7
|
import { i as listChannelPluginCatalogEntries } from "./plugin-auto-enable-KzIwJe0A.js";
|
|
8
8
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { c as listDeliverableMessageChannels, l as normalizeMessageChannel } from "./message-channel-6KBhOx_o.js";
|
|
2
|
-
import { n as listChannelPlugins } from "./plugins-
|
|
2
|
+
import { n as listChannelPlugins } from "./plugins-Czjx5qei.js";
|
|
3
3
|
|
|
4
4
|
//#region src/infra/outbound/channel-selection.ts
|
|
5
5
|
const getMessageChannels = () => listDeliverableMessageChannels();
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { k as theme, st as getActivePluginRegistry } from "./entry.js";
|
|
2
|
-
import { N as resolveConfiguredModelRef, bt as DEFAULT_PROVIDER, yt as DEFAULT_MODEL } from "./auth-profiles-
|
|
2
|
+
import { N as resolveConfiguredModelRef, bt as DEFAULT_PROVIDER, yt as DEFAULT_MODEL } from "./auth-profiles-BJV-XXxt.js";
|
|
3
3
|
import { t as DEFAULT_ACCOUNT_ID } from "./session-key-BmNnF5dG.js";
|
|
4
|
-
import { i as loadConfig } from "./config-
|
|
5
|
-
import { n as listChannelPlugins } from "./plugins-
|
|
6
|
-
import { L as listThinkingLevels, m as formatRawAssistantErrorForUi } from "./pi-embedded-helpers-
|
|
7
|
-
import { it as listChannelDocks } from "./sandbox-
|
|
4
|
+
import { i as loadConfig } from "./config-DxY4DsNc.js";
|
|
5
|
+
import { n as listChannelPlugins } from "./plugins-Czjx5qei.js";
|
|
6
|
+
import { L as listThinkingLevels, m as formatRawAssistantErrorForUi } from "./pi-embedded-helpers-sNJhkxlO.js";
|
|
7
|
+
import { it as listChannelDocks } from "./sandbox-BlIjYgKj.js";
|
|
8
8
|
import { n as formatTokenCount } from "./usage-format-byZKzM9f.js";
|
|
9
9
|
import { createRequire } from "node:module";
|
|
10
10
|
import path from "node:path";
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { g as formatRawAssistantErrorForUi, z as listThinkingLevels } from "./pi-embedded-helpers-
|
|
1
|
+
import { g as formatRawAssistantErrorForUi, z as listThinkingLevels } from "./pi-embedded-helpers-UcI7GOJy.js";
|
|
2
2
|
import { t as DEFAULT_ACCOUNT_ID } from "./session-key-DrNCyvP1.js";
|
|
3
3
|
import { C as getActivePluginRegistry, R as theme } from "./subsystem-B6KC_eUM.js";
|
|
4
4
|
import { Ct as DEFAULT_PROVIDER, St as DEFAULT_MODEL, d as resolveConfiguredModelRef } from "./model-selection-BVecmGTV.js";
|
|
5
|
-
import { i as loadConfig } from "./config-
|
|
5
|
+
import { i as loadConfig } from "./config-nVdFpcsN.js";
|
|
6
6
|
import { n as listChannelPlugins } from "./plugins-Dy91ZCOv.js";
|
|
7
|
-
import { H as listChannelDocks } from "./sandbox-
|
|
7
|
+
import { H as listChannelDocks } from "./sandbox-wOHQvch6.js";
|
|
8
8
|
import { n as formatTokenCount } from "./usage-format-DvowRSs-.js";
|
|
9
9
|
import { createRequire } from "node:module";
|
|
10
10
|
import path from "node:path";
|