@outerlayer/cli 0.36.0-next.20261102124202 → 0.36.0-next.20261102135508
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/agent-setup-Q3HDN23U.js +39 -0
- package/dist/agent-subcommand-Z6SOLWZW.js +25 -0
- package/dist/{bridge-DFG2GTXQ.js → bridge-4KPODDN7.js} +6 -4
- package/dist/{build-THAD3B4Q.js → build-KYXFZQ33.js} +13 -11
- package/dist/{build-disk-HO2VPIBJ.js → build-disk-W6AL5WHI.js} +11 -9
- package/dist/build-info.json +1 -1
- package/dist/{builder-AXJNIF4S.js → builder-IMNOEYV7.js} +10 -8
- package/dist/caller-NLRE272L.js +22 -0
- package/dist/{check-SF2OVZXB.js → check-WWX32IGY.js} +60 -58
- package/dist/{chunk-KN4VIK53.js → chunk-2YC3TXWX.js} +1 -1
- package/dist/{chunk-4TNUQLXH.js → chunk-3UFX6KH2.js} +12 -11
- package/dist/{chunk-5FIOUQGC.js → chunk-3YEPLVNW.js} +8 -8
- package/dist/chunk-4DLJ343I.js +38 -0
- package/dist/{chunk-5WYT3PPE.js → chunk-4OD45RBP.js} +4 -1
- package/dist/{chunk-OYKAOHX5.js → chunk-4XXBV37R.js} +6 -6
- package/dist/{chunk-RSRZDF3K.js → chunk-6B3V6EGQ.js} +11 -9
- package/dist/{chunk-XABJMU5A.js → chunk-6HDXRDC5.js} +2 -2
- package/dist/{chunk-TWYHSMHM.js → chunk-6JLYU322.js} +3 -2
- package/dist/{chunk-5GHJFETA.js → chunk-6KH3NMIT.js} +3010 -1196
- package/dist/{chunk-QJDX6VJS.js → chunk-AQE6E54X.js} +10 -9
- package/dist/{chunk-564Q2STF.js → chunk-ATKCHMFD.js} +1 -1
- package/dist/{chunk-PQDFW422.js → chunk-B2P72DAE.js} +1 -1
- package/dist/{chunk-GZ75FRLB.js → chunk-B36NSEUM.js} +1 -1
- package/dist/{chunk-XHFSBSIA.js → chunk-B5SWBFVE.js} +3 -2
- package/dist/{chunk-NC3QAHOS.js → chunk-BSPJI5T7.js} +4 -2
- package/dist/{chunk-I6FRCBMU.js → chunk-BUYXEU7J.js} +8 -8
- package/dist/{chunk-A5Y2HBVU.js → chunk-BZSJ77MO.js} +1 -1
- package/dist/{chunk-C3JWWPLC.js → chunk-CDG475ZP.js} +8 -7
- package/dist/{chunk-TYCZVJTB.js → chunk-CSBW4LGL.js} +5 -5
- package/dist/{chunk-EUDG754F.js → chunk-CSVJGW3I.js} +2 -2
- package/dist/{chunk-M2NIHHQI.js → chunk-CXJC3JLN.js} +3 -2
- package/dist/{chunk-XE3DIJJT.js → chunk-D4VGJQY7.js} +1 -1
- package/dist/{chunk-PKO5IDW4.js → chunk-D5I5SSPU.js} +7 -7
- package/dist/{chunk-WDQPBAFV.js → chunk-D6EXW4EB.js} +2 -1
- package/dist/{chunk-GSXGA6KF.js → chunk-DG3M5DZU.js} +1 -1
- package/dist/{chunk-GD6KIHOS.js → chunk-DTCTXDJP.js} +1 -1
- package/dist/{chunk-J7Y3PCO2.js → chunk-DTQPDMHG.js} +2 -1
- package/dist/{chunk-PT34C6SU.js → chunk-E3TP4QTM.js} +1 -1
- package/dist/{chunk-NWBB2SQ4.js → chunk-ENBOAE2W.js} +24 -24
- package/dist/{chunk-LSXHTBAM.js → chunk-ENMX3VQ7.js} +7 -7
- package/dist/{chunk-XLOM2BNL.js → chunk-FOSYM7TQ.js} +1 -1
- package/dist/{chunk-4CTVN3C5.js → chunk-FRMAQ3C4.js} +5 -5
- package/dist/{chunk-PTPF36Q7.js → chunk-FTP7SE6Y.js} +3 -3
- package/dist/{chunk-IP7BIBXJ.js → chunk-FWSVWPMS.js} +16 -7
- package/dist/{chunk-K3X3L5YW.js → chunk-GFZ7PELR.js} +6 -6
- package/dist/{chunk-WLMAGMTU.js → chunk-H2NJG3TE.js} +4 -3
- package/dist/{chunk-T5Z22NA6.js → chunk-HRHWA6TZ.js} +1 -1
- package/dist/chunk-HTRDL42C.js +45 -0
- package/dist/{chunk-YBAVN6WS.js → chunk-I4DM7SNX.js} +7 -7
- package/dist/{chunk-CKPQOQFC.js → chunk-I6U6QPN6.js} +769 -101
- package/dist/{chunk-6JJITHBI.js → chunk-IKFAJTLZ.js} +1 -1
- package/dist/{chunk-FIO6PIZ6.js → chunk-J2OMKFYB.js} +3 -3
- package/dist/{chunk-Q42K6XZ6.js → chunk-K2G3VB7W.js} +1 -1
- package/dist/{chunk-L3JXQDVH.js → chunk-K7N6LAPC.js} +4 -4
- package/dist/{chunk-RK4JQRVT.js → chunk-KRCU66AM.js} +9 -9
- package/dist/{chunk-RPZIHELI.js → chunk-LHHDX7FB.js} +5 -5
- package/dist/{chunk-FUJUFLDC.js → chunk-LO4CK734.js} +8 -14
- package/dist/chunk-LSLK4RS4.js +82 -0
- package/dist/{chunk-I626B72C.js → chunk-LSZUTI6O.js} +1 -1
- package/dist/{chunk-H2FFONRY.js → chunk-MVPOYQQY.js} +1 -1
- package/dist/{chunk-JVCQZDQ6.js → chunk-NXQK2I3G.js} +1 -1
- package/dist/{chunk-EBIYRRJW.js → chunk-O3MJAHLI.js} +80 -94
- package/dist/{chunk-VRQM4A64.js → chunk-PBGNX3PS.js} +1 -1
- package/dist/{chunk-CJJDJ7AT.js → chunk-PIZA7OG2.js} +5 -3
- package/dist/{chunk-772ILTCK.js → chunk-PMA67TIN.js} +3 -3
- package/dist/{chunk-GDZTL6BI.js → chunk-QKOJ22OV.js} +123 -277
- package/dist/{chunk-WNYH42PF.js → chunk-RF4JHGGB.js} +7 -7
- package/dist/{chunk-WQB3XOEP.js → chunk-SJJXDU2J.js} +6 -6
- package/dist/chunk-T5QBWM6M.js +113 -0
- package/dist/{chunk-LYFLUNWK.js → chunk-TJIFYV2Z.js} +7 -7
- package/dist/{chunk-OZOATEK3.js → chunk-TKY3SDXH.js} +6 -6
- package/dist/{chunk-CVGQ3BNF.js → chunk-ULBYRPAP.js} +1 -1
- package/dist/{chunk-LVXR37OG.js → chunk-URHS76GV.js} +9 -8
- package/dist/{chunk-J7TCTARR.js → chunk-VAYVTUU4.js} +5 -5
- package/dist/{chunk-5FND4PIU.js → chunk-VUH7KKVD.js} +3 -3
- package/dist/{chunk-NTMRMBLM.js → chunk-WACPWYMH.js} +4 -4
- package/dist/{chunk-AAGU5FJF.js → chunk-WGC7UFRM.js} +1 -1
- package/dist/{chunk-XAOIHYPS.js → chunk-WVAXJOWG.js} +5 -4
- package/dist/{chunk-6LO62EQ5.js → chunk-XEWG4AB2.js} +28 -28
- package/dist/{chunk-AYLYAOHH.js → chunk-XIDDJSQU.js} +3 -2
- package/dist/{chunk-ESSJPSJ2.js → chunk-Y4E7IS7H.js} +2 -2
- package/dist/{chunk-HIN4BMRW.js → chunk-YJQ7YA7J.js} +5 -5
- package/dist/{chunk-LCOQN6NR.js → chunk-YMVRCSKD.js} +4 -4
- package/dist/{chunk-JXXHLQQR.js → chunk-YYQ5NOT5.js} +3 -3
- package/dist/chunk-ZHQC43NH.js +130 -0
- package/dist/{chunk-3FSKTGM6.js → chunk-ZSRMJOAK.js} +3 -3
- package/dist/{claude-launcher-LXZPTDNC.js → claude-launcher-LGKJZH33.js} +82 -108
- package/dist/{cli-QFUT3UQS.js → cli-Q5L64EEG.js} +323 -293
- package/dist/{command-45RZT4CK.js → command-CGEFJZNC.js} +55 -53
- package/dist/{config-WYQPXLOP.js → config-T22KVOOT.js} +12 -10
- package/dist/{connect-cmd-LUCQ7FSV.js → connect-cmd-RUBP466E.js} +12 -10
- package/dist/{container-start-T776VI3M.js → container-start-JRF3SBUA.js} +53 -51
- package/dist/{context-cleanup-QE2MIO2Q.js → context-cleanup-3K2AOECJ.js} +4 -2
- package/dist/{context-show-cmd-7QEHUOEL.js → context-show-cmd-4UXO5WQJ.js} +13 -11
- package/dist/{control-plane-launch-THUH6YU5.js → control-plane-launch-AAH4YH56.js} +25 -21
- package/dist/{demo-record-cmd-SBERRQNW.js → demo-record-cmd-2OKCGST7.js} +7 -5
- package/dist/{demo-voice-cmd-VM3FITZU.js → demo-voice-cmd-GEPX7GIG.js} +24 -22
- package/dist/{dist-6KGTCWKR.js → dist-VVZIGSAF.js} +1 -1
- package/dist/{docker-MQNLK4OO.js → docker-5VWK335X.js} +10 -8
- package/dist/{doctor-NQOSPJGS.js → doctor-EQM3JRZI.js} +55 -53
- package/dist/emit-artifact-cmd-TA3MPHLU.js +43 -0
- package/dist/{emit-cmd-ZPFCPVSR.js → emit-cmd-RO4L4PFZ.js} +7 -5
- package/dist/emit-criteria-cmd-NMTUV2KM.js +34 -0
- package/dist/{emit-demo-cmd-PMQGNNVX.js → emit-demo-cmd-Y2Y6LEL7.js} +24 -22
- package/dist/{emit-finding-cmd-MYWQN5WW.js → emit-finding-cmd-VECM64UR.js} +17 -15
- package/dist/{emit-result-cmd-GXK3KMAP.js → emit-result-cmd-2ERWFDUN.js} +22 -20
- package/dist/{emit-step-cmd-ZV2XTUVT.js → emit-step-cmd-V2ET66N4.js} +17 -15
- package/dist/{exec-client-P7RFRUCK.js → exec-client-54XKNPTI.js} +7 -5
- package/dist/find-unit-CNAPU7XQ.js +23 -0
- package/dist/{findings-cmd-OGMBVVSM.js → findings-cmd-QJPPF6BY.js} +17 -15
- package/dist/{fleet-readiness-4RBKLXBQ.js → fleet-readiness-DKAPHAZN.js} +13 -11
- package/dist/{governing-source-XJMXFSAR.js → governing-source-7PZ6DAJU.js} +21 -19
- package/dist/{guest-init-XZHRPIMG.js → guest-init-5QZRGP62.js} +8 -6
- package/dist/{hook-fast-ZOWGWCPO.js → hook-fast-VXROB4KF.js} +4 -2
- package/dist/{pending-YU2GE2UV.js → hook-install-GDNRMML4.js} +5 -5
- package/dist/{hook-wrap-fast-545QJSBJ.js → hook-wrap-fast-LWWKKPGK.js} +4 -2
- package/dist/host-checks-WAPO5X7X.js +78 -0
- package/dist/host-key-HLLV37NV.js +16 -0
- package/dist/{image-tag-E4JK2APF.js → image-tag-PBWQBATH.js} +7 -5
- package/dist/index.js +8 -9
- package/dist/init-EK3PUU6W.js +78 -0
- package/dist/{init-LO6U7YTW.js → init-Y2URPVVY.js} +51 -49
- package/dist/{init-cmd-2JANO5EN.js → init-cmd-XNANUDIW.js} +35 -29
- package/dist/{init-update-D6PRTGNE.js → init-update-EFCTKF6D.js} +24 -22
- package/dist/{install-cmd-SJMBNQEH.js → install-cmd-RHFUZFV4.js} +9 -7
- package/dist/{layout-AQHIMJMO.js → layout-7XMC7S6K.js} +4 -2
- package/dist/{logs-NE55HOET.js → logs-E7MGQINH.js} +6 -4
- package/dist/loop-L6TX6OR4.js +89 -0
- package/dist/machine-VJKAY2GX.js +78 -0
- package/dist/{machine-skills-KK2HXYMR.js → machine-skills-HR4RNRNR.js} +4 -2
- package/dist/{mcp-install-cmd-2QAS3AQZ.js → mcp-install-cmd-SMPLT43Q.js} +4 -2
- package/dist/{mcp-serve-cmd-U6USKHYR.js → mcp-serve-cmd-XXERT673.js} +8 -6
- package/dist/{paths-O7LCWY33.js → paths-F2ZR2EKC.js} +6 -4
- package/dist/pending-VOFQRXP4.js +16 -0
- package/dist/{pidfile-5GDCQ5HA.js → pidfile-7M7O2M7T.js} +7 -5
- package/dist/{record-NETSDAO6.js → record-YCJ6DZOY.js} +7 -5
- package/dist/{relay-VZ733BVJ.js → relay-I2T43PPB.js} +4 -2
- package/dist/{relay-protocol-24GEUGCO.js → relay-protocol-GI2GC2AM.js} +4 -2
- package/dist/runner-env-YW55JVU7.js +23 -0
- package/dist/{runner-identity-PSCZBILD.js → runner-identity-Y5ZFCC7V.js} +10 -8
- package/dist/{runner-key-VM2LYVRK.js → runner-key-R47C6374.js} +51 -49
- package/dist/{session-sender-P2RHDM6U.js → session-sender-UPACLRGG.js} +23 -21
- package/dist/{shell-function-NRD4KVUK.js → shell-function-GYD2ZQQG.js} +2 -1
- package/dist/{spec-cmd-LGKP6MT7.js → spec-cmd-7QRE2SZK.js} +18 -16
- package/dist/{starter-pack-SMK6UPRL.js → starter-pack-IMKIUA56.js} +5 -3
- package/dist/state-VAHBIMS5.js +16 -0
- package/dist/{status-HEHCNIDS.js → status-BQEYEG2V.js} +51 -49
- package/dist/{statusline-fast-E7RWVREA.js → statusline-fast-NUVHCNRX.js} +4 -2
- package/dist/{sync-cmd-HKN45HXL.js → sync-cmd-NBLYEPQG.js} +22 -20
- package/dist/update-steps-VGKNGWTZ.js +79 -0
- package/dist/{watch-RGZCUCR3.js → watch-IHV4V3HZ.js} +22 -20
- package/dist/{work-claim-cmd-6DSPGCZE.js → work-claim-cmd-WGTSU5IT.js} +21 -19
- package/dist/{work-cmd-GPLYLWY7.js → work-cmd-HKOJU5FJ.js} +15 -13
- package/dist/{work-comment-cmd-V5WM7LAW.js → work-comment-cmd-H3JCWQ2J.js} +18 -16
- package/dist/{work-demo-cmd-SWWI6AGD.js → work-demo-cmd-J4AZAIVP.js} +15 -13
- package/dist/{work-launch-TTGSHLY4.js → work-launch-LWDQXLGI.js} +1 -1
- package/dist/{work-logs-cmd-CTFBOPCI.js → work-logs-cmd-UOO4JVLG.js} +15 -13
- package/dist/{work-open-pr-cmd-HX2U3YBR.js → work-open-pr-cmd-QFRDDBAM.js} +17 -15
- package/dist/{work-pr-cmd-EI2R4FQG.js → work-pr-cmd-3Q2D5RQT.js} +16 -14
- package/dist/{work-proofs-cmd-QXNPHLYC.js → work-proofs-cmd-7Y3HGT7C.js} +18 -16
- package/dist/{work-proofs-record-72OKWEES.js → work-proofs-record-QPUM6DY4.js} +28 -26
- package/dist/{work-stop-cmd-7M7ZYUN2.js → work-stop-cmd-SD2ZRMSY.js} +15 -13
- package/package.json +1 -1
- package/dist/agent-setup-AOB76EDJ.js +0 -37
- package/dist/caller-GOY2X6QT.js +0 -20
- package/dist/chunk-KYDEBGJG.js +0 -402
- package/dist/emit-artifact-cmd-6E365VBQ.js +0 -41
- package/dist/emit-criteria-cmd-HWQOYZZ4.js +0 -32
- package/dist/find-unit-63SXQ7IM.js +0 -21
- package/dist/host-checks-WHW24PJR.js +0 -76
- package/dist/host-key-MWLXB5U5.js +0 -14
- package/dist/init-EZIAHBMH.js +0 -76
- package/dist/loop-2E34CGCX.js +0 -87
- package/dist/machine-6ALGG4IO.js +0 -76
- package/dist/runner-env-KHCONH2R.js +0 -21
- package/dist/settings-XB2HYBKO.js +0 -7
- package/dist/state-RJR4PMMX.js +0 -14
- package/dist/update-steps-7E4RD47J.js +0 -77
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
3
|
import { readNewestDemo } from './chunk-ER6KQCVJ.js';
|
|
4
|
-
import { runEmitArtifact } from './chunk-
|
|
4
|
+
import { runEmitArtifact } from './chunk-6B3V6EGQ.js';
|
|
5
5
|
import { VoiceDownloadError, downloadPinned, sha256OfFile } from './chunk-2PGI6RDE.js';
|
|
6
|
-
import { detectActiveSession } from './chunk-
|
|
7
|
-
import { autoConnect } from './chunk-
|
|
6
|
+
import { detectActiveSession } from './chunk-FWSVWPMS.js';
|
|
7
|
+
import { autoConnect } from './chunk-VUH7KKVD.js';
|
|
8
|
+
import { resolveRepoIdentity } from './chunk-6KH3NMIT.js';
|
|
8
9
|
import { C } from './chunk-2AM6Z5BP.js';
|
|
9
|
-
import { defaultFetch, resolveGatewayCredentials } from './chunk-
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import { VOICE_PACK_FILES, VOICE_PACK_VERSION } from './chunk-J7Y3PCO2.js';
|
|
10
|
+
import { defaultFetch, resolveGatewayCredentials } from './chunk-NXQK2I3G.js';
|
|
11
|
+
import { launchedItemForSession } from './chunk-4OD45RBP.js';
|
|
12
|
+
import { VOICE_PACK_FILES, VOICE_PACK_VERSION } from './chunk-DTQPDMHG.js';
|
|
13
13
|
import { ARTIFACT_MAX_BYTES, ARTIFACT_MAX_CAPTION_LENGTH, DEMO_RECORD_MEDIA_TYPE, ARTIFACT_MAX_REPLACES_TARGETS, DEMO_MANIFEST_LATEST_VERSION, DemoManifestSchema, ARTIFACT_KINDS } from './chunk-WUKLQWGY.js';
|
|
14
14
|
import { homeFromEnv } from './chunk-352DHUTP.js';
|
|
15
15
|
import { __commonJS, __require, __toESM } from './chunk-Z5GEFMRW.js';
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
3
|
import { sanitizeTerminal } from './chunk-P6PHY33P.js';
|
|
4
|
-
import { isAgentsMdLayout } from './chunk-
|
|
5
|
-
import { resolveGatewayCredentials, defaultFetch } from './chunk-
|
|
6
|
-
import { versionAtLeast } from './chunk-
|
|
4
|
+
import { isAgentsMdLayout } from './chunk-D6EXW4EB.js';
|
|
5
|
+
import { resolveGatewayCredentials, defaultFetch } from './chunk-NXQK2I3G.js';
|
|
6
|
+
import { versionAtLeast } from './chunk-BSPJI5T7.js';
|
|
7
7
|
import { findGitDirs } from './chunk-BJ3KTMDH.js';
|
|
8
|
-
import { machineSkillsState, staleAgentSkills } from './chunk-
|
|
8
|
+
import { machineSkillsState, staleAgentSkills } from './chunk-LSZUTI6O.js';
|
|
9
9
|
import { cliInvocation } from './chunk-FZKNTIOJ.js';
|
|
10
|
-
import { hasSymlinkComponent } from './chunk-
|
|
11
|
-
import { skillDir, emitTree, targetIds, classifyTree, emitBuilders, AGENTS_SKILLS_BASE, defaultAgents, namesCore, MACHINE_SKILL_PATH, skillBases, isMaintainedCopy, contextAgents, loadTemplateFiles, splitRawFile } from './chunk-
|
|
10
|
+
import { hasSymlinkComponent } from './chunk-PBGNX3PS.js';
|
|
11
|
+
import { skillDir, emitTree, targetIds, classifyTree, emitBuilders, AGENTS_SKILLS_BASE, defaultAgents, namesCore, MACHINE_SKILL_PATH, skillBases, isMaintainedCopy, contextAgents, loadTemplateFiles, splitRawFile } from './chunk-I6U6QPN6.js';
|
|
12
12
|
import { MAINTAINED_SKILLS } from './chunk-CDDED64E.js';
|
|
13
13
|
import { execFileSync } from 'child_process';
|
|
14
14
|
import { existsSync, readFileSync, writeFileSync, realpathSync, readdirSync } from 'fs';
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { createRequire } from 'node:module';
|
|
3
|
+
import { LEGACY_AGENT } from './chunk-LSLK4RS4.js';
|
|
4
|
+
|
|
5
|
+
createRequire(import.meta.url);
|
|
6
|
+
|
|
7
|
+
// ../agents/src/claude-code/hooks.ts
|
|
8
|
+
var REGISTERED = [
|
|
9
|
+
["SessionStart", "session-start"],
|
|
10
|
+
["SessionEnd", "session-ended"],
|
|
11
|
+
["Stop", "turn-ended"],
|
|
12
|
+
["PostToolUse", "tool-used"]
|
|
13
|
+
];
|
|
14
|
+
var KIND_BY_NAME = new Map(REGISTERED);
|
|
15
|
+
var TOOL_KINDS = {
|
|
16
|
+
Bash: "shell",
|
|
17
|
+
Read: "read",
|
|
18
|
+
Edit: "edit",
|
|
19
|
+
MultiEdit: "edit",
|
|
20
|
+
Write: "edit",
|
|
21
|
+
NotebookEdit: "edit",
|
|
22
|
+
Grep: "search",
|
|
23
|
+
Glob: "search",
|
|
24
|
+
Agent: "spawn",
|
|
25
|
+
Task: "spawn"
|
|
26
|
+
};
|
|
27
|
+
function toolKind(name) {
|
|
28
|
+
if (name === void 0) return void 0;
|
|
29
|
+
if (name.startsWith("mcp__")) return "mcp";
|
|
30
|
+
return TOOL_KINDS[name] ?? "other";
|
|
31
|
+
}
|
|
32
|
+
function parsePayload(stdin) {
|
|
33
|
+
try {
|
|
34
|
+
const parsed = stdin === "" ? {} : JSON.parse(stdin);
|
|
35
|
+
return typeof parsed === "object" && parsed !== null && !Array.isArray(parsed) ? parsed : {};
|
|
36
|
+
} catch {
|
|
37
|
+
return {};
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
var text = (value) => typeof value === "string" ? value : void 0;
|
|
41
|
+
function decode(name, stdin) {
|
|
42
|
+
const payload = parsePayload(stdin);
|
|
43
|
+
const nativeName = String(name ?? payload.hook_event_name ?? "unknown");
|
|
44
|
+
const kind = KIND_BY_NAME.get(nativeName);
|
|
45
|
+
const sessionId = text(payload.session_id);
|
|
46
|
+
const cwd = text(payload.cwd);
|
|
47
|
+
const transcript = text(payload.transcript_path);
|
|
48
|
+
const toolName = text(payload.tool_name);
|
|
49
|
+
const toolUseId = text(payload.tool_use_id);
|
|
50
|
+
const tool = toolKind(toolName);
|
|
51
|
+
return {
|
|
52
|
+
nativeName,
|
|
53
|
+
...kind === void 0 ? {} : { kind },
|
|
54
|
+
...kind !== void 0 && sessionId !== void 0 && cwd !== void 0 && transcript !== void 0 ? {
|
|
55
|
+
event: {
|
|
56
|
+
kind,
|
|
57
|
+
sessionId,
|
|
58
|
+
cwd,
|
|
59
|
+
session: { agent: "claude-code", id: sessionId, locator: { kind: "file", path: transcript } },
|
|
60
|
+
...kind === "tool-used" && tool !== void 0 ? { tool } : {}
|
|
61
|
+
}
|
|
62
|
+
} : {},
|
|
63
|
+
spool: {
|
|
64
|
+
sessionId: payload.session_id ?? null,
|
|
65
|
+
transcriptPath: payload.transcript_path ?? null,
|
|
66
|
+
cwd: payload.cwd ?? null,
|
|
67
|
+
payloadEvent: payload.hook_event_name ?? null
|
|
68
|
+
},
|
|
69
|
+
// A tool call a subagent makes carries the subagent's id.
|
|
70
|
+
fromSubagent: payload.agent_id !== void 0,
|
|
71
|
+
...toolName === void 0 && toolUseId === void 0 ? {} : { tool: { ...toolUseId === void 0 ? {} : { useId: toolUseId }, ...toolName === void 0 ? {} : { name: toolName } } }
|
|
72
|
+
};
|
|
73
|
+
}
|
|
74
|
+
function reply(value) {
|
|
75
|
+
switch (value.kind) {
|
|
76
|
+
case "session-start":
|
|
77
|
+
return JSON.stringify({
|
|
78
|
+
...value.notice === void 0 ? {} : { systemMessage: value.notice },
|
|
79
|
+
hookSpecificOutput: { hookEventName: "SessionStart", additionalContext: value.context }
|
|
80
|
+
});
|
|
81
|
+
case "tool-used":
|
|
82
|
+
return JSON.stringify({ hookSpecificOutput: { hookEventName: "PostToolUse", additionalContext: value.context } });
|
|
83
|
+
case "turn-ended":
|
|
84
|
+
return JSON.stringify({ decision: "block", reason: value.continueWith });
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
function statusLine(stdin) {
|
|
88
|
+
const payload = parsePayload(stdin);
|
|
89
|
+
const cost = payload.cost?.total_cost_usd;
|
|
90
|
+
const sessionId = text(payload.session_id);
|
|
91
|
+
return {
|
|
92
|
+
...sessionId === void 0 ? {} : { sessionId },
|
|
93
|
+
...typeof cost === "number" ? { costUsd: cost } : {}
|
|
94
|
+
};
|
|
95
|
+
}
|
|
96
|
+
var CLAUDE_CODE_HOOKS = {
|
|
97
|
+
events: REGISTERED.map(([name]) => name),
|
|
98
|
+
decode,
|
|
99
|
+
reply,
|
|
100
|
+
statusLine
|
|
101
|
+
};
|
|
102
|
+
|
|
103
|
+
// ../agents/src/native/hook-codecs.ts
|
|
104
|
+
var HOOK_CODECS = {
|
|
105
|
+
"claude-code": CLAUDE_CODE_HOOKS
|
|
106
|
+
};
|
|
107
|
+
|
|
108
|
+
// ../agents/src/lifecycle.ts
|
|
109
|
+
function hookCodec(agentId) {
|
|
110
|
+
return HOOK_CODECS[agentId ?? LEGACY_AGENT];
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
export { CLAUDE_CODE_HOOKS, hookCodec };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
-
import { toolsDockerfile } from './chunk-
|
|
4
|
-
import { claimPidFile, RunnerAlreadyRunningError, releasePidFile } from './chunk-
|
|
3
|
+
import { toolsDockerfile } from './chunk-ZSRMJOAK.js';
|
|
4
|
+
import { claimPidFile, RunnerAlreadyRunningError, releasePidFile } from './chunk-D4VGJQY7.js';
|
|
5
5
|
import { startTimeOf } from './chunk-JBJTC3UU.js';
|
|
6
|
-
import { runnerLabelValue } from './chunk-
|
|
7
|
-
import { RecipeError, locateRecipe, readRecipe, assertBuildable, writeSanitizedRecipe, classifyProperties, SANITIZED_NAME } from './chunk-
|
|
8
|
-
import { RUNNER_DIR_MODE, RUNNER_FILE_MODE, repoCacheDir, imagesDir, imageBuildLogsDir, attemptStamp, orgStore, rootfsPathFor } from './chunk-
|
|
9
|
-
import { withGitConfig, tokenHeader } from './chunk-
|
|
10
|
-
import { UNIVERSAL_IMAGE_DIGEST, UNIVERSAL_IMAGE_REPOSITORY, UNIVERSAL_IMAGE_SOURCE, buildAgentPin, NODE_IMAGE, UNIVERSAL_IMAGE, MEDIA_PINS, TINI_VERSION, GH_VERSION } from './chunk-
|
|
6
|
+
import { runnerLabelValue } from './chunk-CDG475ZP.js';
|
|
7
|
+
import { RecipeError, locateRecipe, readRecipe, assertBuildable, writeSanitizedRecipe, classifyProperties, SANITIZED_NAME } from './chunk-BZSJ77MO.js';
|
|
8
|
+
import { RUNNER_DIR_MODE, RUNNER_FILE_MODE, repoCacheDir, imagesDir, imageBuildLogsDir, attemptStamp, orgStore, rootfsPathFor } from './chunk-DTCTXDJP.js';
|
|
9
|
+
import { withGitConfig, tokenHeader } from './chunk-CXJC3JLN.js';
|
|
10
|
+
import { UNIVERSAL_IMAGE_DIGEST, UNIVERSAL_IMAGE_REPOSITORY, UNIVERSAL_IMAGE_SOURCE, buildAgentPin, NODE_IMAGE, UNIVERSAL_IMAGE, MEDIA_PINS, TINI_VERSION, GH_VERSION } from './chunk-DTQPDMHG.js';
|
|
11
11
|
import { mkdirSync, rmSync, writeFileSync, existsSync, mkdtempSync, cpSync, readFileSync, readdirSync, lstatSync, readlinkSync } from 'fs';
|
|
12
12
|
import { tmpdir } from 'os';
|
|
13
13
|
import { dirname, join } from 'path';
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
-
import { launchRefusalForSession } from './chunk-
|
|
4
|
-
import { detectActiveSession, transcriptPathForSession } from './chunk-
|
|
5
|
-
import { autoConnect } from './chunk-
|
|
3
|
+
import { launchRefusalForSession } from './chunk-WGC7UFRM.js';
|
|
4
|
+
import { detectActiveSession, transcriptPathForSession } from './chunk-FWSVWPMS.js';
|
|
5
|
+
import { autoConnect } from './chunk-VUH7KKVD.js';
|
|
6
|
+
import { resolveRepoIdentity, defaultProjectsDir, findTranscripts, sessionIdFromPath, scrubText } from './chunk-6KH3NMIT.js';
|
|
6
7
|
import { C } from './chunk-2AM6Z5BP.js';
|
|
7
|
-
import { resolveGatewayCredentials, defaultFetch, unauthorizedMessage } from './chunk-
|
|
8
|
+
import { resolveGatewayCredentials, defaultFetch, unauthorizedMessage } from './chunk-NXQK2I3G.js';
|
|
8
9
|
import { readLatestProvenanceForSession } from './chunk-545P7JY7.js';
|
|
9
|
-
import {
|
|
10
|
-
import { launchedItemForSession } from './chunk-5WYT3PPE.js';
|
|
10
|
+
import { launchedItemForSession } from './chunk-4OD45RBP.js';
|
|
11
11
|
import { parseTrackerNumber, trackerNumberError } from './chunk-WZBHBH3J.js';
|
|
12
12
|
import { cliInvocation } from './chunk-FZKNTIOJ.js';
|
|
13
13
|
import { FindingBatchSchema, FindingsResponseSchema, SAME_PROBLEM_RULES } from './chunk-WUKLQWGY.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
3
|
import { isVersion, compareVersions } from './chunk-TQMI335S.js';
|
|
4
|
-
import { RUNNER_DIR_MODE, RUNNER_FILE_MODE } from './chunk-
|
|
4
|
+
import { RUNNER_DIR_MODE, RUNNER_FILE_MODE } from './chunk-DTCTXDJP.js';
|
|
5
5
|
import { readFileSync, mkdirSync, writeFileSync, renameSync } from 'fs';
|
|
6
6
|
import { join } from 'path';
|
|
7
7
|
|
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
-
import { runEmit } from './chunk-
|
|
4
|
-
import { addStdioMcpEntryIfAbsent, addDocsMcpEntryIfAbsent, DOCS_MCP_SERVER_NAME } from './chunk-
|
|
5
|
-
import { installStarterPack } from './chunk-
|
|
6
|
-
import { listWithAnd } from './chunk-
|
|
3
|
+
import { runEmit } from './chunk-WVAXJOWG.js';
|
|
4
|
+
import { addStdioMcpEntryIfAbsent, addDocsMcpEntryIfAbsent, DOCS_MCP_SERVER_NAME } from './chunk-MVPOYQQY.js';
|
|
5
|
+
import { installStarterPack } from './chunk-B5SWBFVE.js';
|
|
6
|
+
import { listWithAnd } from './chunk-FRMAQ3C4.js';
|
|
7
|
+
import { AGENTS_MD_LAYOUT, mcpFiles, declareAgentsMdLayout, linkAgentSkills, describeSkillsLink, isAgentsMdLayout, holdsTodaysLayoutSources, discoverOuterlayerPaths } from './chunk-D6EXW4EB.js';
|
|
7
8
|
import { C } from './chunk-2AM6Z5BP.js';
|
|
8
|
-
import {
|
|
9
|
-
import { resolveGitCommonDir, defaultGitRunner } from './chunk-J7TCTARR.js';
|
|
9
|
+
import { resolveGitCommonDir, defaultGitRunner } from './chunk-VAYVTUU4.js';
|
|
10
10
|
import { cliInvocation } from './chunk-FZKNTIOJ.js';
|
|
11
|
-
import { linkedAgentsPath } from './chunk-
|
|
11
|
+
import { linkedAgentsPath } from './chunk-PBGNX3PS.js';
|
|
12
12
|
import { cloneIsGoverned } from './chunk-YQR6E6OV.js';
|
|
13
|
-
import {
|
|
13
|
+
import { generatedHeaderSource, defaultAgents, loadTemplateFiles, loadMaintainedFiles, skillDir, AGENTS_SKILLS_BASE, legacyAgent, contextAgents } from './chunk-I6U6QPN6.js';
|
|
14
|
+
import { LEGACY_AGENT } from './chunk-LSLK4RS4.js';
|
|
14
15
|
import { execFileSync } from 'child_process';
|
|
15
16
|
import { existsSync, mkdirSync, writeFileSync } from 'fs';
|
|
16
17
|
import { join, dirname } from 'path';
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
-
import { RemovedTargetError, removedTargetError } from './chunk-
|
|
4
|
-
import { removeRetiredSkills } from './chunk-
|
|
5
|
-
import { defaultFetch, resolveGatewayCredentials } from './chunk-
|
|
3
|
+
import { RemovedTargetError, removedTargetError } from './chunk-XIDDJSQU.js';
|
|
4
|
+
import { removeRetiredSkills } from './chunk-B36NSEUM.js';
|
|
5
|
+
import { defaultFetch, resolveGatewayCredentials } from './chunk-NXQK2I3G.js';
|
|
6
6
|
import { appendContextProvenance } from './chunk-545P7JY7.js';
|
|
7
7
|
import { cliInvocation } from './chunk-FZKNTIOJ.js';
|
|
8
8
|
import { writeDegraded, writeSourceCache, SOURCE_CACHE_TTL_RETRY_MS, writeContextManifest, SOURCE_CACHE_TTL_SUCCESS_MS, readSourceCache, isSourceCacheFresh, clearDegraded } from './chunk-YQR6E6OV.js';
|
|
9
|
-
import { withTokenHeader } from './chunk-
|
|
10
|
-
import { normalizeRepoName, loadMaintainedFiles, writeMaintainedFiles, parseOuterlayerConfig, targetIds, classifyTree, emitTree, emitBuilders, defaultAgents, agentRootFolders } from './chunk-
|
|
9
|
+
import { withTokenHeader } from './chunk-CXJC3JLN.js';
|
|
10
|
+
import { normalizeRepoName, loadMaintainedFiles, writeMaintainedFiles, parseOuterlayerConfig, targetIds, classifyTree, emitTree, emitBuilders, defaultAgents, agentRootFolders } from './chunk-I6U6QPN6.js';
|
|
11
11
|
import { homeFromEnv } from './chunk-352DHUTP.js';
|
|
12
12
|
import { execFileSync } from 'child_process';
|
|
13
13
|
import { existsSync, mkdirSync, writeFileSync, chmodSync, lstatSync, readFileSync, copyFileSync } from 'fs';
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
-
import { fetchFactories, selectFactory, saveFactoryConnection, autoConnectedLine } from './chunk-
|
|
4
|
-
import {
|
|
3
|
+
import { fetchFactories, selectFactory, saveFactoryConnection, autoConnectedLine } from './chunk-FRMAQ3C4.js';
|
|
4
|
+
import { resolveRepoIdentity } from './chunk-6KH3NMIT.js';
|
|
5
|
+
import { resolveGatewayCredentials } from './chunk-NXQK2I3G.js';
|
|
5
6
|
import { readCloudConfig } from './chunk-HWVMRETT.js';
|
|
6
7
|
import { findGitDirs, readRepoConnection } from './chunk-BJ3KTMDH.js';
|
|
7
|
-
import { resolveRepoIdentity } from './chunk-5GHJFETA.js';
|
|
8
8
|
import { cliInvocation } from './chunk-FZKNTIOJ.js';
|
|
9
9
|
import { homeFromEnv } from './chunk-352DHUTP.js';
|
|
10
10
|
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
-
import { DEFAULT_CACHE_DISK, DEFAULT_BUILD_DISK } from './chunk-
|
|
4
|
-
import { parseSize } from './chunk-
|
|
5
|
-
import { isRefusedInConfig, resolveDestinations, isReservedVariable } from './chunk-
|
|
6
|
-
import { builderDiskPinned } from './chunk-
|
|
3
|
+
import { DEFAULT_CACHE_DISK, DEFAULT_BUILD_DISK } from './chunk-Y4E7IS7H.js';
|
|
4
|
+
import { parseSize } from './chunk-CDG475ZP.js';
|
|
5
|
+
import { isRefusedInConfig, resolveDestinations, isReservedVariable } from './chunk-CXJC3JLN.js';
|
|
6
|
+
import { builderDiskPinned } from './chunk-DTQPDMHG.js';
|
|
7
7
|
import { homeFromEnv } from './chunk-352DHUTP.js';
|
|
8
8
|
import { existsSync, statSync, accessSync, constants, readFileSync } from 'fs';
|
|
9
9
|
import { hostname } from 'os';
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
+
import { isAgentsMdLayout, discoverOuterlayerPaths, isForeignTree, toRepoRelative } from './chunk-D6EXW4EB.js';
|
|
3
4
|
import { C } from './chunk-2AM6Z5BP.js';
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { retiredSkillPaths, removeRetiredSkills } from './chunk-GZ75FRLB.js';
|
|
5
|
+
import { invalidConfigMessage } from './chunk-XIDDJSQU.js';
|
|
6
|
+
import { retiredSkillPaths, removeRetiredSkills } from './chunk-B36NSEUM.js';
|
|
7
7
|
import { cliInvocation } from './chunk-FZKNTIOJ.js';
|
|
8
|
-
import { maintainedFilesForExistingSkills, loadMaintainedFiles, emitTree, emitBuilders, defaultAgents, targetIds, generatedHeaderSource, parseOuterlayerConfig, classifyTree, writeMaintainedFiles,
|
|
8
|
+
import { maintainedFilesForExistingSkills, loadMaintainedFiles, emitTree, emitBuilders, defaultAgents, targetIds, generatedHeaderSource, parseOuterlayerConfig, classifyTree, writeMaintainedFiles, agentById } from './chunk-I6U6QPN6.js';
|
|
9
|
+
import { LEGACY_AGENT } from './chunk-LSLK4RS4.js';
|
|
9
10
|
import { existsSync, readFileSync, mkdirSync, writeFileSync, copyFileSync, unlinkSync, rmdirSync, readdirSync } from 'fs';
|
|
10
11
|
import { join, dirname } from 'path';
|
|
11
12
|
|
|
@@ -1,40 +1,40 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
-
import { itemsSentence, criteriaOf, hostItemsOf, loadCitationFinder, testFileMatcher, MAX_TEST_FILE_BYTES, MAX_TEST_FILES, criterionInputs, uncitedIds, planCriteria, parseJudgeAnswer, inCriteriaOrder, oneLineReason, judgedItems, IdScan, firstInPathOrder, isSearchCandidate } from './chunk-
|
|
3
|
+
import { itemsSentence, criteriaOf, hostItemsOf, loadCitationFinder, testFileMatcher, MAX_TEST_FILE_BYTES, MAX_TEST_FILES, criterionInputs, uncitedIds, planCriteria, parseJudgeAnswer, inCriteriaOrder, oneLineReason, judgedItems, IdScan, firstInPathOrder, isSearchCandidate } from './chunk-FOSYM7TQ.js';
|
|
4
4
|
import { zodProblem } from './chunk-I3LTIAOR.js';
|
|
5
5
|
import { sha256OfFile, downloadPinned, VoiceDownloadError } from './chunk-2PGI6RDE.js';
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
6
|
+
import { hasStoredCredential, AGENT_COMMANDS, storeAgentCredential, credentialFromStdin, isAgentName } from './chunk-K7N6LAPC.js';
|
|
7
|
+
import { upgradedStarterText } from './chunk-LHHDX7FB.js';
|
|
8
|
+
import { HELPER_PATH, HELPER_RECORD, DOCKERD_LOG } from './chunk-J2OMKFYB.js';
|
|
9
|
+
import { senderPidfile } from './chunk-YMVRCSKD.js';
|
|
10
|
+
import { installScrubContext } from './chunk-3UFX6KH2.js';
|
|
9
11
|
import { readsJobState, READ_JOB_STATE_FORMATS, jobStateFormatOf } from './chunk-ZVB57WI6.js';
|
|
10
|
-
import { runnerImageVersion } from './chunk-
|
|
11
|
-
import {
|
|
12
|
+
import { runnerImageVersion } from './chunk-ULBYRPAP.js';
|
|
13
|
+
import { claimCalls, spoolHomeFor, itemCalls, claimItem, leftByRunnerKey } from './chunk-CSVJGW3I.js';
|
|
12
14
|
import { receiveFiles } from './chunk-NN33FYXG.js';
|
|
13
|
-
import { readDefaultBranchFiles, readDefaultBranchHead, cloneRepository, buildRepositoryImage, fetchCommit, readBranchHead, diffBetween, prepareImageBuild, KEY_PREFIX, TAG_HOST, SHARED_OWNER, SHARED_NAME, universalBase, metadataFromLabels, writeRecord } from './chunk-
|
|
14
|
-
import { FETCHED_DIR, toolsDockerfile, FETCHED_FFMPEG, FETCHED_GH, FETCHED_TINI, FETCHED_HEADLESS_SHELL, FETCHED_PLAYWRIGHT_FFMPEG, FETCHED_VOICE_DIR } from './chunk-
|
|
15
|
-
import { currentCliBuild } from './chunk-OGFGZQA3.js';
|
|
16
|
-
import { vmExecArgs, runExec, execCapture, waitForAgent } from './chunk-T5Z22NA6.js';
|
|
17
|
-
import { describeCallFailure, shortClaim, retrySend, commandWithShim, logStamp, createRunnerLog, formatDuration, removeKeptContext, formatClock, stageGovernedContext, keptContextTree, removeStagedContext, WORKFLOW_PERMISSION_REASON, refusalCode, resolveGoverningSource, prefetchGovernedContext, controlPlaneTokenFailure, keepStagedContext, pinnedSourceOf, shimScript } from './chunk-5FIOUQGC.js';
|
|
18
|
-
import { HELPER_PATH, HELPER_RECORD, DOCKERD_LOG } from './chunk-FIO6PIZ6.js';
|
|
15
|
+
import { readDefaultBranchFiles, readDefaultBranchHead, cloneRepository, buildRepositoryImage, fetchCommit, readBranchHead, diffBetween, prepareImageBuild, KEY_PREFIX, TAG_HOST, SHARED_OWNER, SHARED_NAME, universalBase, metadataFromLabels, writeRecord } from './chunk-TJIFYV2Z.js';
|
|
16
|
+
import { FETCHED_DIR, toolsDockerfile, FETCHED_FFMPEG, FETCHED_GH, FETCHED_TINI, FETCHED_HEADLESS_SHELL, FETCHED_PLAYWRIGHT_FFMPEG, FETCHED_VOICE_DIR } from './chunk-ZSRMJOAK.js';
|
|
19
17
|
import { isSameProcess, startTimeOf } from './chunk-JBJTC3UU.js';
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
18
|
+
import { currentCliBuild } from './chunk-OGFGZQA3.js';
|
|
19
|
+
import { vmExecArgs, runExec, execCapture, waitForAgent } from './chunk-HRHWA6TZ.js';
|
|
20
|
+
import { socketPathProblem, vsockLinks, linkVsockSockets, GUEST_CID, LEASE_LINK } from './chunk-H2NJG3TE.js';
|
|
21
|
+
import { describeCallFailure, shortClaim, retrySend, commandWithShim, logStamp, createRunnerLog, formatDuration, removeKeptContext, formatClock, stageGovernedContext, keptContextTree, removeStagedContext, WORKFLOW_PERMISSION_REASON, refusalCode, resolveGoverningSource, prefetchGovernedContext, controlPlaneTokenFailure, keepStagedContext, pinnedSourceOf, shimScript } from './chunk-3YEPLVNW.js';
|
|
22
|
+
import { writeDockerClientConfig } from './chunk-2YC3TXWX.js';
|
|
23
|
+
import { runnerCredentialProblem, builtinKind, keyRunnerFactory, optionalEgress, isBuiltinContainer, isBuiltinProcess, isBuiltinVm, egressSummary, DEFAULT_CHECK_TIME_LIMIT_MINUTES, DEFAULT_SETUP_MINUTES, allowHostProblem, systemClock, emptyEgressCounts, hostAllowed, imageBuildOf, DEFAULT_SAVED_STATE_MAX_BYTES } from './chunk-WACPWYMH.js';
|
|
24
|
+
import { formatBytes, volumeBytes, allocatedBytes, DEFAULT_BUILD_DISK, DEFAULT_CACHE_DISK, freeBytes } from './chunk-Y4E7IS7H.js';
|
|
25
|
+
import { writeJobFile, readJobFile, spawnRun, RUNNER_LABEL, BUILD_LABEL, NETWORK_HELPER_MEMORY, createDockerHost, builderSpec, containerExecArgs, childEnvironment, readDu, withAnswerProtocol, judgeCommand, MAX_REPORT_BYTES, readJobFileChecked, NETWORK_READY_FILE, networkHelperName, runnerLabelValue, prepareRunArgs, containerRunArgs, JUDGE_MAX_TURNS, parseSize, homeCopyRunArgs, networkHelperRunArgs, JUDGE_DIR, HASH_ARGV, parseProgramHash, identityScript, identityArgs, parseIdentity, mountableHome, homeCopyScript, homeCopyArgs, COMMAND_DIR, JUDGE_PROGRAM, MAX_ITEMS_BYTES, JUDGE_ITEMS, JUDGE_REPORT, identityRunArgs, SAVED_STATE_LABEL } from './chunk-CDG475ZP.js';
|
|
26
|
+
import { universalImagePending, RecipeError, writeSanitizedRecipe, classifyProperties, DOCKER_FEATURE } from './chunk-BZSJ77MO.js';
|
|
27
|
+
import { postJson, WorkCommandError, getJson, isSignatureRefusal } from './chunk-AQE6E54X.js';
|
|
28
28
|
import { sanitizeTerminal, planArtifactUpload } from './chunk-P6PHY33P.js';
|
|
29
|
+
import { scrubText, MIN_SCRUBBED_LITERAL, setCustomScrubbers, setLocalIdentity, setRepoRoot, forkFor, parseTranscript, scrubDeep } from './chunk-6KH3NMIT.js';
|
|
29
30
|
import { readCloudConfig } from './chunk-HWVMRETT.js';
|
|
30
|
-
import { signerFor } from './chunk-
|
|
31
|
-
import { sharedSkillNames, skillConflictMessage } from './chunk-
|
|
32
|
-
import { versionAtLeast, MINIMUM_CLAUDE_VERSION } from './chunk-
|
|
33
|
-
import {
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
36
|
-
import {
|
|
37
|
-
import { defaultAgents, parsePolicy, AGENTS_SKILLS_BASE, OUTERLAYER_SKILLS_BASE, resolvePackRoot, orderSessions, extractFacts, sessionsToTimeline } from './chunk-CKPQOQFC.js';
|
|
31
|
+
import { signerFor } from './chunk-IKFAJTLZ.js';
|
|
32
|
+
import { sharedSkillNames, skillConflictMessage } from './chunk-6JLYU322.js';
|
|
33
|
+
import { versionAtLeast, MINIMUM_CLAUDE_VERSION } from './chunk-BSPJI5T7.js';
|
|
34
|
+
import { vmAssetsDir, RUNNER_DIR_MODE, RUNNER_FILE_MODE, runnerDir, buildDir, jobsDir, storeScopes, spoolDir, orgStoreIn, rootfsDir, imagesDir, sessionsDir, builderCacheDiskPath, buildsDir, ghConfigDir, runnerDirOfBuild, mirrorDir, orgHomeDir, jobConsolePath, vsockPath, builderConsolePath, rootfsPathFor, diskTemplatesDir, deliveryDir, SHIM_DIR } from './chunk-DTCTXDJP.js';
|
|
35
|
+
import { CHECKOUT_DIR, JOB_MOUNT, buildEnvironment, parseIsolation, proxyEnvironment, withProxyWarningHidden, containerLocalAddress, destinationEnvironment, withHooksPath, startBuildServices, sharedUserEnvironment, headerVariables, authorEnvironment, withTunnelRecord, commitIdentityRecord, repositoriesOf, RELAY_PORT, repositoryPath, lifecycleWorkdir, CHECK_ITEMS_FILE, checkEnvironment, withMiseVariables, checkoutPath, EVAL_INPUT_DIR, isMiseVariableAllowed, BUILD_HOME, primaryOf } from './chunk-CXJC3JLN.js';
|
|
36
|
+
import { firecrackerArch, MICROVM_ARCHES, FIRECRACKER_VERSION, hostHelperPinned, builderDiskPinned, guestAssetsPinned, runnerAgentNamed, credentialForms, orList, credentialShapes, credentialAgent, agentCredential, strippedVariables, builtInEnvironment, builtInNames, buildAgent, AGENT_CREDENTIAL_MISSING, RUNNER_WORDED_REASONS, UNKNOWN_TRACKING_REASON, UNKNOWN_TRANSPORT_REASON, GUEST_HELPER_SHA256, GUEST_ASSETS_BASE_URL, GUEST_KERNEL_SHA256, JAILER_BINARY_SHA256, FIRECRACKER_BINARY_SHA256, FIRECRACKER_SHA256, GUEST_ASSETS_VERSION, BUILDER_DISK_VERSION, credentialHandOffKey, runnerAgents, currentAgentCredential, removedAgentCredentialValues, managedAgentCredential, RELAY_USER, realFdStorePort, networkHelperPinned, NETWORK_HELPER_SHA256, universalImagePinned, UNIVERSAL_IMAGE, MAX_MALFORMED_SESSIONS, MALFORMED_REASON, JOIN_WAIT_MS, FFMPEG_STATIC, FFMPEG_BUILD_TAG, GH_SHA256, GH_VERSION, TINI_SHA256, TINI_VERSION, HEADLESS_SHELL, HEADLESS_SHELL_BASE_URL, PLAYWRIGHT_FFMPEG, PLAYWRIGHT_FFMPEG_BASE_URL, VOICE_PACK_FILES, BUILDER_DISK_SHA256, BUILDER_DISK_BASE_URL, DEFAULT_BASE_IMAGE, MAX_OPEN_STREAMS, STREAM_RESET_RATE, STREAM_RESET_BURST, STREAM_WINDOW, SESSION_WINDOW, targetOfPath, agentVersionOf, fdName, RELAY_ID, DOCKER_DESKTOP_REASON } from './chunk-DTQPDMHG.js';
|
|
37
|
+
import { defaultAgents, parsePolicy, AGENTS_SKILLS_BASE, OUTERLAYER_SKILLS_BASE, resolvePackRoot, orderSessions, extractFacts, sessionsToTimeline } from './chunk-I6U6QPN6.js';
|
|
38
38
|
import { CheckItemsSchema, downconvertSession } from './chunk-WUKLQWGY.js';
|
|
39
39
|
import { MAINTAINED_SKILLS } from './chunk-CDDED64E.js';
|
|
40
40
|
import { resolveVersion } from './chunk-RA3O54FC.js';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
-
import { parseOuterlayerConfig, targetIds, defaultAgents } from './chunk-
|
|
3
|
+
import { parseOuterlayerConfig, targetIds, defaultAgents } from './chunk-I6U6QPN6.js';
|
|
4
|
+
import { NATIVE_AGENTS, LEGACY_AGENT } from './chunk-LSLK4RS4.js';
|
|
4
5
|
import { readFileSync } from 'fs';
|
|
5
6
|
import { join } from 'path';
|
|
6
7
|
|
|
@@ -24,7 +25,7 @@ function removedTargetErrorIn(root, agents = defaultAgents()) {
|
|
|
24
25
|
return removedTargetError(text, agents);
|
|
25
26
|
}
|
|
26
27
|
function launchRefusal(repository, error) {
|
|
27
|
-
return `outerlayer
|
|
28
|
+
return `outerlayer ${NATIVE_AGENTS[LEGACY_AGENT].legacy.subcommand}: the control plane ${repository} has an ${error}
|
|
28
29
|
`;
|
|
29
30
|
}
|
|
30
31
|
function buildRefusalReason(repository, error) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
-
import { parseSize, BUILD_LABEL, RUNNER_LABEL, runnerLabelValue } from './chunk-
|
|
4
|
-
import { buildsDir, storeScopes, rootfsDir, orgStoreIn, runnerDir, imagesDir, builderCacheDiskPath } from './chunk-
|
|
3
|
+
import { parseSize, BUILD_LABEL, RUNNER_LABEL, runnerLabelValue } from './chunk-CDG475ZP.js';
|
|
4
|
+
import { buildsDir, storeScopes, rootfsDir, orgStoreIn, runnerDir, imagesDir, builderCacheDiskPath } from './chunk-DTCTXDJP.js';
|
|
5
5
|
import { spawnSync } from 'child_process';
|
|
6
6
|
import { statfsSync, statSync, existsSync, readdirSync } from 'fs';
|
|
7
7
|
import { dirname, join } from 'path';
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
-
import { detectActiveSession } from './chunk-
|
|
4
|
-
import { autoConnect } from './chunk-
|
|
3
|
+
import { detectActiveSession } from './chunk-FWSVWPMS.js';
|
|
4
|
+
import { autoConnect } from './chunk-VUH7KKVD.js';
|
|
5
|
+
import { resolveRepoIdentity } from './chunk-6KH3NMIT.js';
|
|
5
6
|
import { C } from './chunk-2AM6Z5BP.js';
|
|
6
|
-
import { defaultFetch, unauthorizedMessage, resolveGatewayCredentials } from './chunk-
|
|
7
|
-
import {
|
|
8
|
-
import { parseWorkItemEnv } from './chunk-5WYT3PPE.js';
|
|
7
|
+
import { defaultFetch, unauthorizedMessage, resolveGatewayCredentials } from './chunk-NXQK2I3G.js';
|
|
8
|
+
import { parseWorkItemEnv } from './chunk-4OD45RBP.js';
|
|
9
9
|
import { parseTrackerNumber, trackerNumberError } from './chunk-WZBHBH3J.js';
|
|
10
10
|
import { homeFromEnv } from './chunk-352DHUTP.js';
|
|
11
11
|
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
-
import { LiveUploader } from './chunk-
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { parseWorkItemEnv } from './chunk-
|
|
3
|
+
import { LiveUploader } from './chunk-3UFX6KH2.js';
|
|
4
|
+
import { CaptureDaemon } from './chunk-6KH3NMIT.js';
|
|
5
|
+
import { spoolDir } from './chunk-O3MJAHLI.js';
|
|
6
|
+
import { parseWorkItemEnv } from './chunk-4OD45RBP.js';
|
|
7
7
|
import { homeFromEnv } from './chunk-352DHUTP.js';
|
|
8
8
|
import { mkdirSync, writeFileSync, rmSync } from 'fs';
|
|
9
9
|
import { join } from 'path';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
-
import { stripTerminalControls } from './chunk-
|
|
4
|
-
import { tagToPull, imageTag, pullInstruction, readUpdateStatus, runnerImageVersion } from './chunk-
|
|
3
|
+
import { stripTerminalControls } from './chunk-XEWG4AB2.js';
|
|
4
|
+
import { tagToPull, imageTag, pullInstruction, readUpdateStatus, runnerImageVersion } from './chunk-ULBYRPAP.js';
|
|
5
5
|
import { readFileSync } from 'fs';
|
|
6
6
|
|
|
7
7
|
createRequire(import.meta.url);
|
|
@@ -55,7 +55,7 @@ function envNamesOf(row, imageEnv) {
|
|
|
55
55
|
return [...new Set(names)].sort();
|
|
56
56
|
}
|
|
57
57
|
async function readOwnContainer(deps = {}) {
|
|
58
|
-
const run = deps.run ?? (await import('./docker-
|
|
58
|
+
const run = deps.run ?? (await import('./docker-5VWK335X.js')).spawnRun;
|
|
59
59
|
const ids = candidateIds(deps.env ?? process.env, deps.readFile ?? ((path) => readFileSync(path, "utf8")));
|
|
60
60
|
if (ids.length === 0) return { ok: false, reason: "the runner cannot tell which container it runs in: HOSTNAME is empty and /proc/self/mountinfo names none" };
|
|
61
61
|
let problem = "";
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { createRequire } from 'node:module';
|
|
3
|
+
import { existsSync, readFileSync, mkdirSync, copyFileSync, writeFileSync } from 'fs';
|
|
4
|
+
import { dirname } from 'path';
|
|
5
|
+
|
|
6
|
+
createRequire(import.meta.url);
|
|
7
|
+
function tokenizeCommand(command) {
|
|
8
|
+
const tokens = [];
|
|
9
|
+
let current = "";
|
|
10
|
+
let inToken = false;
|
|
11
|
+
let quote = null;
|
|
12
|
+
for (const ch of command) {
|
|
13
|
+
if (quote !== null) {
|
|
14
|
+
if (ch === quote) quote = null;
|
|
15
|
+
else current += ch;
|
|
16
|
+
} else if (ch === '"' || ch === "'") {
|
|
17
|
+
quote = ch;
|
|
18
|
+
inToken = true;
|
|
19
|
+
} else if (/\s/.test(ch)) {
|
|
20
|
+
if (inToken) {
|
|
21
|
+
tokens.push(current);
|
|
22
|
+
current = "";
|
|
23
|
+
inToken = false;
|
|
24
|
+
}
|
|
25
|
+
} else {
|
|
26
|
+
current += ch;
|
|
27
|
+
inToken = true;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
if (quote !== null) return null;
|
|
31
|
+
if (inToken) tokens.push(current);
|
|
32
|
+
return tokens;
|
|
33
|
+
}
|
|
34
|
+
function quoteBin(bin) {
|
|
35
|
+
return /\s/.test(bin) ? `"${bin}"` : bin;
|
|
36
|
+
}
|
|
37
|
+
function isScriptBin(bin) {
|
|
38
|
+
return /\.[cm]?js$/i.test(bin);
|
|
39
|
+
}
|
|
40
|
+
function cliCommand(cliBin) {
|
|
41
|
+
return isScriptBin(cliBin) ? `node ${quoteBin(cliBin)}` : quoteBin(cliBin);
|
|
42
|
+
}
|
|
43
|
+
var PORTABLE_BIN = "outerlayer";
|
|
44
|
+
function isOurBin(bin, cliBin) {
|
|
45
|
+
if (cliBin !== void 0 && normalizeBinPath(bin) === normalizeBinPath(cliBin)) return true;
|
|
46
|
+
const parts = bin.replace(/\\/g, "/").split("/");
|
|
47
|
+
if (isPublishedPackageBin(parts)) return true;
|
|
48
|
+
const base = (parts.pop() ?? "").toLowerCase();
|
|
49
|
+
if (base === "outerlayer" || base === "outerlayer.exe" || base === "outerlayer.cmd") return true;
|
|
50
|
+
return parts.some((p) => p.toLowerCase() === ".outerlayer");
|
|
51
|
+
}
|
|
52
|
+
function isPublishedPackageBin(parts) {
|
|
53
|
+
const n = parts.length;
|
|
54
|
+
if (n === 2 && parts[0] === "@outerlayer" && /^cli(@[^/]+)?$/.test(parts[1])) return true;
|
|
55
|
+
return parts[n - 4] === "@outerlayer" && parts[n - 3] === "cli" && parts[n - 2] === "dist" && parts[n - 1] === "index.js";
|
|
56
|
+
}
|
|
57
|
+
function normalizeBinPath(bin) {
|
|
58
|
+
return bin.replace(/\\/g, "/");
|
|
59
|
+
}
|
|
60
|
+
function splitCliInvocation(command, cliBin) {
|
|
61
|
+
if (typeof command !== "string") return null;
|
|
62
|
+
const tokens = tokenizeCommand(command.trim());
|
|
63
|
+
if (!tokens) return null;
|
|
64
|
+
const launcher = (tokens[0] ?? "").replace(/\\/g, "/").split("/").pop() ?? "";
|
|
65
|
+
const viaNode = launcher === "node" || launcher === "node.exe";
|
|
66
|
+
const viaNpx = launcher === "npx";
|
|
67
|
+
const i = viaNode || viaNpx ? 1 : 0;
|
|
68
|
+
const bin = tokens[i];
|
|
69
|
+
if (!bin || !isOurBin(bin, cliBin)) return null;
|
|
70
|
+
return { bin, args: tokens.slice(i + 1), viaNpx, viaNode };
|
|
71
|
+
}
|
|
72
|
+
function parseCliInvocation(command, cliBin) {
|
|
73
|
+
return splitCliInvocation(command, cliBin)?.args ?? null;
|
|
74
|
+
}
|
|
75
|
+
function decodeVerifiedWrapId(token) {
|
|
76
|
+
if (typeof token !== "string") return null;
|
|
77
|
+
const original = decodeWrappedCommand(token);
|
|
78
|
+
const canonical = encodeWrappedCommand(original);
|
|
79
|
+
return canonical.replace(/=+$/, "") === token.replace(/=+$/, "") ? original : null;
|
|
80
|
+
}
|
|
81
|
+
function cliBinResolvable(cliBin) {
|
|
82
|
+
if (!cliBin.includes("/") && !cliBin.includes("\\")) return true;
|
|
83
|
+
return existsSync(cliBin);
|
|
84
|
+
}
|
|
85
|
+
function encodeWrappedCommand(command) {
|
|
86
|
+
return Buffer.from(command, "utf8").toString("base64");
|
|
87
|
+
}
|
|
88
|
+
function decodeWrappedCommand(id) {
|
|
89
|
+
return Buffer.from(id, "base64").toString("utf8");
|
|
90
|
+
}
|
|
91
|
+
function readSettingsText(path) {
|
|
92
|
+
return existsSync(path) ? readFileSync(path, "utf8") : void 0;
|
|
93
|
+
}
|
|
94
|
+
var SettingsParseError = class extends Error {
|
|
95
|
+
constructor(path, cause) {
|
|
96
|
+
super(`refusing to modify ${path}: it is not valid JSON (${cause instanceof Error ? cause.message : cause})`);
|
|
97
|
+
this.path = path;
|
|
98
|
+
this.cause = cause;
|
|
99
|
+
this.name = "SettingsParseError";
|
|
100
|
+
}
|
|
101
|
+
};
|
|
102
|
+
function writeSettingsText(path, text, now = Date.now) {
|
|
103
|
+
mkdirSync(dirname(path), { recursive: true });
|
|
104
|
+
let backupPath;
|
|
105
|
+
if (existsSync(path)) {
|
|
106
|
+
backupPath = `${path}.bak-${now()}`;
|
|
107
|
+
copyFileSync(path, backupPath);
|
|
108
|
+
}
|
|
109
|
+
writeFileSync(path, text);
|
|
110
|
+
return backupPath;
|
|
111
|
+
}
|
|
112
|
+
function cliForInstall(bin) {
|
|
113
|
+
return {
|
|
114
|
+
command(args) {
|
|
115
|
+
if (bin === void 0) throw new Error("this command line has no CLI to run");
|
|
116
|
+
return `${cliCommand(bin)} ${args}`;
|
|
117
|
+
},
|
|
118
|
+
parse: (command) => parseCliInvocation(command, bin),
|
|
119
|
+
split(command) {
|
|
120
|
+
const split = splitCliInvocation(command, bin);
|
|
121
|
+
return split === null ? null : { ...split, script: isScriptBin(split.bin) };
|
|
122
|
+
},
|
|
123
|
+
startsLikeCommand: (split) => bin !== void 0 && normalizeBinPath(split.bin) === normalizeBinPath(bin) && split.viaNode === isScriptBin(bin),
|
|
124
|
+
encode: encodeWrappedCommand,
|
|
125
|
+
decode: decodeVerifiedWrapId,
|
|
126
|
+
resolvable: () => bin !== void 0 && cliBinResolvable(bin)
|
|
127
|
+
};
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
export { PORTABLE_BIN, SettingsParseError, cliBinResolvable, cliForInstall, decodeWrappedCommand, readSettingsText, writeSettingsText };
|