@dadado/agent-kit-cli 6.25.0 → 6.26.1
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/dashboard/dashboard.html +3 -3
- package/dashboard/lib/guards.mjs +1 -0
- package/dist/{add-OYLOMCM6.js → add-G7KEZLWP.js} +7 -6
- package/dist/{chunk-7HDQEK6T.js → chunk-2G4K4ZI5.js} +7 -3
- package/dist/{chunk-QLTGHJB3.js → chunk-2GXN7HVG.js} +5 -5
- package/dist/{chunk-IFBIO7VT.js → chunk-3KFLQE6Y.js} +1533 -52
- package/dist/{chunk-GQSSXDDK.js → chunk-ARJRICI2.js} +1 -1
- package/dist/{chunk-6WUKLS4D.js → chunk-BIFTTL2O.js} +1 -1
- package/dist/{chunk-QACMV46U.js → chunk-BSK6C4UO.js} +19 -12
- package/dist/{chunk-NJ2SUSWX.js → chunk-BVZDPVUL.js} +1 -1
- package/dist/{chunk-GMG7ZH4E.js → chunk-DOMBVLI4.js} +13 -13
- package/dist/{chunk-2F6NMQOA.js → chunk-FB6G6OD6.js} +3 -3
- package/dist/{chunk-MFKHIWEL.js → chunk-FOVHFMSH.js} +1 -1
- package/dist/{chunk-EO5NGAYV.js → chunk-FUSNEYGU.js} +29 -3
- package/dist/{chunk-SAQ3EE5R.js → chunk-HGB4DHXV.js} +3 -3
- package/dist/{chunk-6M6UKECW.js → chunk-IHVJTGYR.js} +0 -32
- package/dist/chunk-KMK4T4ZM.js +34 -0
- package/dist/{chunk-ZMYV6PRE.js → chunk-LEVNLHH3.js} +2 -1
- package/dist/{chunk-2XLI7XEY.js → chunk-MGVV6YC4.js} +1 -1
- package/dist/{chunk-C7SV7UP5.js → chunk-MWRYQLEG.js} +3 -3
- package/dist/{chunk-WKFE3RUC.js → chunk-NHJ4IAVN.js} +5 -3
- package/dist/{chunk-HSIHZWFF.js → chunk-NW5SWKJV.js} +7 -7
- package/dist/{chunk-C4Q77GGJ.js → chunk-O7VMHCNN.js} +6 -0
- package/dist/{chunk-CIV42JGT.js → chunk-PCIYXGB3.js} +2 -2
- package/dist/{chunk-7Y74KO7U.js → chunk-PLLXFSN2.js} +12 -12
- package/dist/{chunk-XGZOU4DS.js → chunk-QMCBXCP5.js} +4 -4
- package/dist/{chunk-QX55T4UX.js → chunk-RJP47EGS.js} +6 -1
- package/dist/{chunk-KWYF7QNH.js → chunk-RLVY6YD3.js} +17 -2
- package/dist/{chunk-JGG574RK.js → chunk-RRJVC35Y.js} +3 -3
- package/dist/{chunk-PIMGV3E5.js → chunk-SWJJW624.js} +1 -1
- package/dist/{chunk-G5MQRP6M.js → chunk-SYRJ5TTK.js} +13 -9
- package/dist/{chunk-L5V3W3DY.js → chunk-TTUFIE26.js} +60 -14
- package/dist/chunk-WOXTL43E.js +248 -0
- package/dist/{chunk-JFS4GKP7.js → chunk-XXPI4H4D.js} +2 -2
- package/dist/{chunk-M4UL422I.js → chunk-Y5526WCN.js} +6 -6
- package/dist/{chunk-CXE6ASSX.js → chunk-Y575INEC.js} +1 -1
- package/dist/{chunk-H7RAFRRZ.js → chunk-YFRG3CMS.js} +68 -34
- package/dist/{chunk-JG3CNGQM.js → chunk-ZNZHDPS3.js} +6 -4
- package/dist/{commands-UW2C2ZN4.js → commands-SCFSX4U4.js} +8 -6
- package/dist/{conflicts-RING6AHV.js → conflicts-4GLQOMJF.js} +9 -10
- package/dist/{contribute-LSY75JZH.js → contribute-HE4WCBRY.js} +7 -6
- package/dist/{countdown-SZ2P4XHB.js → countdown-VXOFV23S.js} +104 -57
- package/dist/{dashboard-P65XHYCU.js → dashboard-6V6PCNYF.js} +1 -1
- package/dist/{dashboard-broadcast-GYK34QYL.js → dashboard-broadcast-PMVQ7PXU.js} +1 -1
- package/dist/{diff-NZVBVQSK.js → diff-3XUZM7ZT.js} +8 -7
- package/dist/{doctor-TJSXBVGV.js → doctor-KGUWU5SN.js} +16 -15
- package/dist/{engine-info-BBI5QO5Y.js → engine-info-VM4VPGQM.js} +2 -2
- package/dist/{ground-control-ZJXPUIQN.js → ground-control-J4AMA4S4.js} +7 -4
- package/dist/{handoff-2OZSWGTE.js → handoff-LLT4CI6H.js} +2 -3
- package/dist/{hook-3VPKNSOO.js → hook-UPZ3CPYS.js} +22 -22
- package/dist/index.js +52 -32
- package/dist/{init-UW2BJBO2.js → init-ZHLVXEVT.js} +19 -18
- package/dist/{install-RQSI4CHG.js → install-XWOG64W3.js} +19 -18
- package/dist/{installs-7TR4H4QH.js → installs-2ROXPO6M.js} +5 -4
- package/dist/{mission-control-VSU6NT43.js → mission-control-IGOI3WHS.js} +2 -2
- package/dist/models-SNB5Q3YU.js +45 -0
- package/dist/paths-JTPV6SXH.js +107 -0
- package/dist/pi-DCMDOY65.js +248 -0
- package/dist/{plan-index-BNLUU6T5.js → plan-index-5QZJK4AG.js} +2 -3
- package/dist/{queue-JHYILLMX.js → queue-HDR5ER25.js} +11 -13
- package/dist/{run-CQF5RM5X.js → run-RGIY5JTX.js} +24 -30
- package/dist/{run-plan-BEOCOJCF.js → run-plan-DHB3ZXJS.js} +35 -23
- package/dist/{session-start-QV7CEFRX.js → session-start-NC2HE5X5.js} +16 -16
- package/dist/{sessions-AWAAO3DU.js → sessions-WWWLYPW6.js} +4 -4
- package/dist/{setup-global-ST4TT427.js → setup-global-WDMARD4Z.js} +11 -10
- package/dist/{status-HUBPBGUU.js → status-2WNJL7PP.js} +12 -11
- package/dist/update-OXCWYN3Y.js +32 -0
- package/dist/{update-all-YYUTXHGR.js → update-all-E2MV6KME.js} +20 -18
- package/package.json +14 -4
- package/pi/agent-kit.ts +224 -0
- package/dist/chunk-7ABY6DYH.js +0 -89
- package/dist/chunk-AQLBEEPD.js +0 -625
- package/dist/chunk-MUTTNRX4.js +0 -53
- package/dist/chunk-TOSAAQ5A.js +0 -71
- package/dist/update-DD5UZPGG.js +0 -31
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
import { createInterface } from "readline";
|
|
7
7
|
import { StringDecoder } from "string_decoder";
|
|
8
8
|
var DRIVER_PROTOCOL_MAJOR = 1;
|
|
9
|
-
var DRIVER_PROTOCOL_VERSION = "1.
|
|
9
|
+
var DRIVER_PROTOCOL_VERSION = "1.6.0";
|
|
10
10
|
var DRIVER_EVENTS_FORMATS = ["ndjson"];
|
|
11
11
|
var INBOUND_MAX_CHARS = 64 * 1024;
|
|
12
12
|
var AGENT_PENDING_MAX_CHARS = 4 * 1024 * 1024;
|
|
@@ -5,37 +5,35 @@ import {
|
|
|
5
5
|
createDriverEmitter,
|
|
6
6
|
driverReplies,
|
|
7
7
|
driverStop
|
|
8
|
-
} from "./chunk-
|
|
9
|
-
import {
|
|
10
|
-
readRunQueueState
|
|
11
|
-
} from "./chunk-7ABY6DYH.js";
|
|
12
|
-
import {
|
|
13
|
-
detectAgentBackend
|
|
14
|
-
} from "./chunk-TOSAAQ5A.js";
|
|
8
|
+
} from "./chunk-BIFTTL2O.js";
|
|
15
9
|
import {
|
|
16
10
|
classifyGateExit,
|
|
17
11
|
landGateExit
|
|
18
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-QMCBXCP5.js";
|
|
19
13
|
import {
|
|
20
14
|
QUEUE_LEASE_INTERRUPT_WAIT_MS,
|
|
21
15
|
QUEUE_LEASE_SESSION_ENV,
|
|
22
16
|
acquireQueueLease,
|
|
23
17
|
forwardTermination,
|
|
24
18
|
gateCheckIn
|
|
25
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-FOVHFMSH.js";
|
|
26
20
|
import {
|
|
27
21
|
buildDispatchPrompt,
|
|
28
22
|
ensureDispatchLogPath,
|
|
29
23
|
readCommandFile,
|
|
30
24
|
runHeadlessDispatch
|
|
31
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-RLVY6YD3.js";
|
|
26
|
+
import {
|
|
27
|
+
detectAgentBackend,
|
|
28
|
+
readRunQueueState
|
|
29
|
+
} from "./chunk-3KFLQE6Y.js";
|
|
32
30
|
import {
|
|
33
31
|
formatHitlSummary,
|
|
34
32
|
hitlExitCode
|
|
35
33
|
} from "./chunk-P7732A25.js";
|
|
36
34
|
import {
|
|
37
35
|
HANDOFF_REL
|
|
38
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-O7VMHCNN.js";
|
|
39
37
|
|
|
40
38
|
// src/plan-loop/dispatch-driver.ts
|
|
41
39
|
import { readFile } from "fs/promises";
|
|
@@ -279,7 +277,16 @@ async function runDispatchDriver(opts) {
|
|
|
279
277
|
write: writeErr,
|
|
280
278
|
checkIn: gateCheckIn(root, () => lease.session, opts.lease)
|
|
281
279
|
},
|
|
282
|
-
onSpawn: (info) => lease.setAgent(info.pid)
|
|
280
|
+
onSpawn: (info) => lease.setAgent(info.pid),
|
|
281
|
+
onProgress: (p) => emitter.emit({
|
|
282
|
+
type: "model_loading",
|
|
283
|
+
tick: DISPATCH_DRIVER_TICK,
|
|
284
|
+
backend: detected.id,
|
|
285
|
+
model: p.model,
|
|
286
|
+
phase: p.phase,
|
|
287
|
+
elapsedMs: p.elapsedMs,
|
|
288
|
+
...p.detail ? { detail: p.detail } : {}
|
|
289
|
+
})
|
|
283
290
|
});
|
|
284
291
|
} catch (err) {
|
|
285
292
|
say(String(err), "error");
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import {
|
|
2
2
|
formatQueueLeaseRefusal,
|
|
3
3
|
inspectQueueLease
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-FOVHFMSH.js";
|
|
5
5
|
import {
|
|
6
6
|
NON_INTERACTIVE_ROOT_ARGS,
|
|
7
7
|
detectStaleCli,
|
|
8
8
|
formatRerunFlags,
|
|
9
9
|
formatStaleCliRefusal,
|
|
10
10
|
syncFromManifest
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-2GXN7HVG.js";
|
|
12
12
|
import {
|
|
13
13
|
formatSkippedSymlinks,
|
|
14
14
|
logApplyStats
|
|
@@ -16,20 +16,20 @@ import {
|
|
|
16
16
|
import {
|
|
17
17
|
REGISTRY_CLI_ARGS,
|
|
18
18
|
resolveRegistryFromCli
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-SWJJW624.js";
|
|
20
20
|
import {
|
|
21
21
|
CLAUDE_SETTINGS_REL,
|
|
22
22
|
formatClaudeSettingsDrift,
|
|
23
23
|
formatPermissionsChanged,
|
|
24
24
|
planClaudeSettingsDrift,
|
|
25
25
|
writeClaudeSessionStartHook
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-BVZDPVUL.js";
|
|
27
27
|
import {
|
|
28
28
|
generateClaudeCommandAdapters
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-FUSNEYGU.js";
|
|
30
30
|
import {
|
|
31
31
|
feedInstallsRegistry
|
|
32
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-NHJ4IAVN.js";
|
|
33
33
|
import {
|
|
34
34
|
withCliProgress
|
|
35
35
|
} from "./chunk-QTON2GQX.js";
|
|
@@ -41,14 +41,14 @@ import {
|
|
|
41
41
|
confirmProjectRoot,
|
|
42
42
|
isNonInteractive,
|
|
43
43
|
syncPathCliToRuntime
|
|
44
|
-
} from "./chunk-
|
|
44
|
+
} from "./chunk-RRJVC35Y.js";
|
|
45
45
|
import {
|
|
46
46
|
checkForUpdates
|
|
47
|
-
} from "./chunk-
|
|
47
|
+
} from "./chunk-Y5526WCN.js";
|
|
48
48
|
import {
|
|
49
49
|
dropRetiredSkillIds,
|
|
50
50
|
formatRetiredSkillDrop
|
|
51
|
-
} from "./chunk-
|
|
51
|
+
} from "./chunk-HGB4DHXV.js";
|
|
52
52
|
import {
|
|
53
53
|
buildManifest,
|
|
54
54
|
canonicalizePackIds,
|
|
@@ -57,13 +57,13 @@ import {
|
|
|
57
57
|
loadAgentKitManifest,
|
|
58
58
|
resolveProtectedGlobs,
|
|
59
59
|
saveManifest
|
|
60
|
-
} from "./chunk-
|
|
60
|
+
} from "./chunk-ZNZHDPS3.js";
|
|
61
61
|
import {
|
|
62
62
|
seedManagedHashLedger
|
|
63
|
-
} from "./chunk-
|
|
63
|
+
} from "./chunk-RJP47EGS.js";
|
|
64
64
|
import {
|
|
65
65
|
KIT_VERSION
|
|
66
|
-
} from "./chunk-
|
|
66
|
+
} from "./chunk-2G4K4ZI5.js";
|
|
67
67
|
|
|
68
68
|
// src/commands/update.ts
|
|
69
69
|
import { defineCommand } from "citty";
|
|
@@ -151,7 +151,7 @@ var updateCommand = defineCommand({
|
|
|
151
151
|
process.exitCode = 1;
|
|
152
152
|
return;
|
|
153
153
|
}
|
|
154
|
-
const { runUpdateAll } = await import("./update-all-
|
|
154
|
+
const { runUpdateAll } = await import("./update-all-E2MV6KME.js");
|
|
155
155
|
const result2 = await runUpdateAll({
|
|
156
156
|
includeWorktrees: args["include-worktrees"],
|
|
157
157
|
applyOptions: {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
listInstalls,
|
|
3
3
|
resolveInstallsFile
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-NHJ4IAVN.js";
|
|
5
5
|
import {
|
|
6
6
|
CLI_NPM_PACKAGES,
|
|
7
7
|
compareSemver,
|
|
@@ -9,13 +9,13 @@ import {
|
|
|
9
9
|
isFactoryOrDevRegistry,
|
|
10
10
|
normalizeSemver,
|
|
11
11
|
updateCheckAllowed
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-Y5526WCN.js";
|
|
13
13
|
import {
|
|
14
14
|
loadContextConfig
|
|
15
15
|
} from "./chunk-PFEUZXVT.js";
|
|
16
16
|
import {
|
|
17
17
|
KIT_VERSION
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-2G4K4ZI5.js";
|
|
19
19
|
import {
|
|
20
20
|
writeJson
|
|
21
21
|
} from "./chunk-5B4DVO6C.js";
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
resolveContained,
|
|
6
6
|
saveManagedHashLedger,
|
|
7
7
|
shouldPreserveCustomizedOverlay
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-RJP47EGS.js";
|
|
9
9
|
import {
|
|
10
10
|
ensureDir,
|
|
11
11
|
fileExists
|
|
@@ -17,13 +17,39 @@ import path from "path";
|
|
|
17
17
|
var CURSOR_COMMANDS_DIR_REL = ".cursor/commands";
|
|
18
18
|
var CLAUDE_COMMANDS_DIR_REL = ".claude/commands";
|
|
19
19
|
var RESERVED_ADAPTER_NAMES = /* @__PURE__ */ new Set(["agent-kit"]);
|
|
20
|
+
function unquoteYamlScalar(value) {
|
|
21
|
+
if (value.length >= 2 && value.startsWith('"') && value.endsWith('"')) {
|
|
22
|
+
try {
|
|
23
|
+
const parsed = JSON.parse(value);
|
|
24
|
+
if (typeof parsed === "string") return parsed;
|
|
25
|
+
} catch {
|
|
26
|
+
}
|
|
27
|
+
return value.slice(1, -1);
|
|
28
|
+
}
|
|
29
|
+
if (value.length >= 2 && value.startsWith("'") && value.endsWith("'")) {
|
|
30
|
+
return value.slice(1, -1).replace(/''/g, "'");
|
|
31
|
+
}
|
|
32
|
+
return value;
|
|
33
|
+
}
|
|
34
|
+
function isPlainYamlSafe(value) {
|
|
35
|
+
if (value === "" || value !== value.trim()) return false;
|
|
36
|
+
if (/[\n\r\t]/.test(value)) return false;
|
|
37
|
+
if (/: |:$| #/.test(value)) return false;
|
|
38
|
+
if (/^[-?:,[\]{}#&*!|>'"%@`]/.test(value)) return false;
|
|
39
|
+
if (/^(?:~|null|true|false|yes|no|on|off|y|n)$/i.test(value)) return false;
|
|
40
|
+
if (/^[-+]?(?:\.?\d|\.(?:inf|nan)$)/i.test(value)) return false;
|
|
41
|
+
return true;
|
|
42
|
+
}
|
|
43
|
+
function yamlScalar(value) {
|
|
44
|
+
return isPlainYamlSafe(value) ? value : JSON.stringify(value);
|
|
45
|
+
}
|
|
20
46
|
function parseCommandFrontmatter(name, raw) {
|
|
21
47
|
const match = /^---\r?\n([\s\S]*?)\r?\n---/.exec(raw);
|
|
22
48
|
if (!match) return null;
|
|
23
49
|
const body = match[1] ?? "";
|
|
24
50
|
const descMatch = /^description:\s*(.+)$/m.exec(body);
|
|
25
51
|
if (!descMatch) return null;
|
|
26
|
-
const description = (descMatch[1] ?? "").trim();
|
|
52
|
+
const description = unquoteYamlScalar((descMatch[1] ?? "").trim()).trim();
|
|
27
53
|
if (!description) return null;
|
|
28
54
|
return { name, description };
|
|
29
55
|
}
|
|
@@ -41,7 +67,7 @@ var MODEL_INVOCATION_DISABLED = /* @__PURE__ */ new Set([
|
|
|
41
67
|
function renderClaudeCommandAdapter(command) {
|
|
42
68
|
const invocation = MODEL_INVOCATION_DISABLED.has(command.name) ? "disable-model-invocation: true\n" : "";
|
|
43
69
|
return `---
|
|
44
|
-
description: ${command.description}
|
|
70
|
+
description: ${yamlScalar(command.description)}
|
|
45
71
|
${invocation}---
|
|
46
72
|
|
|
47
73
|
Read \`.cursor/commands/${command.name}.md\` now and follow that contract exactly \u2014 it is the source of truth for /${command.name}; this file is only a thin adapter for Claude Code.
|
|
@@ -9,14 +9,14 @@ import {
|
|
|
9
9
|
loadRegistry,
|
|
10
10
|
packMemberFileTargets,
|
|
11
11
|
skillFileTargets
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-ZNZHDPS3.js";
|
|
13
13
|
import {
|
|
14
14
|
contentHash,
|
|
15
15
|
resolveContained
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-RJP47EGS.js";
|
|
17
17
|
import {
|
|
18
18
|
MANIFEST_RELATIVE_PATH
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-KMK4T4ZM.js";
|
|
20
20
|
|
|
21
21
|
// src/lifecycle/retired.ts
|
|
22
22
|
import { lstat, readFile, rmdir, unlink } from "fs/promises";
|
|
@@ -1,30 +1,3 @@
|
|
|
1
|
-
import {
|
|
2
|
-
HANDOFF_REL
|
|
3
|
-
} from "./chunk-C4Q77GGJ.js";
|
|
4
|
-
|
|
5
|
-
// src/manifest/types.ts
|
|
6
|
-
var MANIFEST_FILENAME = "agent-kit.json";
|
|
7
|
-
var MANIFEST_RELATIVE_PATH = `.cursor/${MANIFEST_FILENAME}`;
|
|
8
|
-
var MANIFEST_SCHEMA_VERSION = 1;
|
|
9
|
-
var DEFAULT_PROTECTED_PATHS = [
|
|
10
|
-
HANDOFF_REL,
|
|
11
|
-
".cursor/plans/**",
|
|
12
|
-
".cursor/memory/**",
|
|
13
|
-
".cursor/context/config.json",
|
|
14
|
-
".cursor/context/current/**",
|
|
15
|
-
".cursor/context/backups/**"
|
|
16
|
-
];
|
|
17
|
-
var LEGACY_CONTEXT_PROTECTED_GLOB = ".cursor/context/**";
|
|
18
|
-
var DOMAIN_PACK_IDS = [
|
|
19
|
-
"cybersec",
|
|
20
|
-
"devops",
|
|
21
|
-
"engineering-architecture",
|
|
22
|
-
"clean-code",
|
|
23
|
-
"project-management",
|
|
24
|
-
"context-management",
|
|
25
|
-
"quality"
|
|
26
|
-
];
|
|
27
|
-
|
|
28
1
|
// src/utils/dir-lock.ts
|
|
29
2
|
import { randomUUID } from "crypto";
|
|
30
3
|
import { mkdir, readFile, rename, rm, stat, writeFile } from "fs/promises";
|
|
@@ -167,10 +140,5 @@ async function acquireDirLock(target, options = {}) {
|
|
|
167
140
|
}
|
|
168
141
|
|
|
169
142
|
export {
|
|
170
|
-
MANIFEST_RELATIVE_PATH,
|
|
171
|
-
MANIFEST_SCHEMA_VERSION,
|
|
172
|
-
DEFAULT_PROTECTED_PATHS,
|
|
173
|
-
LEGACY_CONTEXT_PROTECTED_GLOB,
|
|
174
|
-
DOMAIN_PACK_IDS,
|
|
175
143
|
acquireDirLock
|
|
176
144
|
};
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import {
|
|
2
|
+
HANDOFF_REL
|
|
3
|
+
} from "./chunk-O7VMHCNN.js";
|
|
4
|
+
|
|
5
|
+
// src/manifest/types.ts
|
|
6
|
+
var MANIFEST_FILENAME = "agent-kit.json";
|
|
7
|
+
var MANIFEST_RELATIVE_PATH = `.cursor/${MANIFEST_FILENAME}`;
|
|
8
|
+
var MANIFEST_SCHEMA_VERSION = 1;
|
|
9
|
+
var DEFAULT_PROTECTED_PATHS = [
|
|
10
|
+
HANDOFF_REL,
|
|
11
|
+
".cursor/plans/**",
|
|
12
|
+
".cursor/memory/**",
|
|
13
|
+
".cursor/context/config.json",
|
|
14
|
+
".cursor/context/current/**",
|
|
15
|
+
".cursor/context/backups/**"
|
|
16
|
+
];
|
|
17
|
+
var LEGACY_CONTEXT_PROTECTED_GLOB = ".cursor/context/**";
|
|
18
|
+
var DOMAIN_PACK_IDS = [
|
|
19
|
+
"cybersec",
|
|
20
|
+
"devops",
|
|
21
|
+
"engineering-architecture",
|
|
22
|
+
"clean-code",
|
|
23
|
+
"project-management",
|
|
24
|
+
"context-management",
|
|
25
|
+
"quality"
|
|
26
|
+
];
|
|
27
|
+
|
|
28
|
+
export {
|
|
29
|
+
MANIFEST_RELATIVE_PATH,
|
|
30
|
+
MANIFEST_SCHEMA_VERSION,
|
|
31
|
+
DEFAULT_PROTECTED_PATHS,
|
|
32
|
+
LEGACY_CONTEXT_PROTECTED_GLOB,
|
|
33
|
+
DOMAIN_PACK_IDS
|
|
34
|
+
};
|
|
@@ -27,7 +27,8 @@ var ROLE_CAPABILITIES = Object.freeze({
|
|
|
27
27
|
"cursor-agent": Object.freeze({ workerModel: true, subworkerModel: false, reviewer: true }),
|
|
28
28
|
codex: Object.freeze({ workerModel: true, subworkerModel: false, reviewer: false }),
|
|
29
29
|
openrouter: Object.freeze({ workerModel: true, subworkerModel: false, reviewer: false }),
|
|
30
|
-
"cursor-acp": Object.freeze({ workerModel: false, subworkerModel: false, reviewer: false })
|
|
30
|
+
"cursor-acp": Object.freeze({ workerModel: false, subworkerModel: false, reviewer: false }),
|
|
31
|
+
local: Object.freeze({ workerModel: true, subworkerModel: false, reviewer: false })
|
|
31
32
|
});
|
|
32
33
|
var CONFIG_ROLE_WORKER_BACKENDS = Object.freeze([
|
|
33
34
|
"auto",
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
managedPairs
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-HGB4DHXV.js";
|
|
4
4
|
import {
|
|
5
5
|
isProtectedPath,
|
|
6
6
|
resolveProtectedGlobs
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-ZNZHDPS3.js";
|
|
8
8
|
import {
|
|
9
9
|
resolveContained
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-RJP47EGS.js";
|
|
11
11
|
|
|
12
12
|
// src/lifecycle/diff.ts
|
|
13
13
|
import { readFile } from "fs/promises";
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import {
|
|
2
|
-
MANIFEST_RELATIVE_PATH,
|
|
3
2
|
acquireDirLock
|
|
4
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-IHVJTGYR.js";
|
|
4
|
+
import {
|
|
5
|
+
MANIFEST_RELATIVE_PATH
|
|
6
|
+
} from "./chunk-KMK4T4ZM.js";
|
|
5
7
|
import {
|
|
6
8
|
KIT_VERSION
|
|
7
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-2G4K4ZI5.js";
|
|
8
10
|
import {
|
|
9
11
|
fileExists
|
|
10
12
|
} from "./chunk-5B4DVO6C.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
isBranchInBase
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-ARJRICI2.js";
|
|
4
4
|
import {
|
|
5
5
|
GATE_EXIT_BRANCH_PREFIX,
|
|
6
6
|
GATE_EXIT_NOTE_DIR,
|
|
@@ -11,22 +11,22 @@ import {
|
|
|
11
11
|
isSafeBaseRef,
|
|
12
12
|
landGateExit,
|
|
13
13
|
resolveGateExitRefs
|
|
14
|
-
} from "./chunk-
|
|
15
|
-
import {
|
|
16
|
-
ensurePathIgnored
|
|
17
|
-
} from "./chunk-MUTTNRX4.js";
|
|
14
|
+
} from "./chunk-QMCBXCP5.js";
|
|
18
15
|
import {
|
|
19
16
|
ensureDispatchLogPath,
|
|
20
17
|
readCommandFile,
|
|
21
18
|
runHeadlessDispatch
|
|
22
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-RLVY6YD3.js";
|
|
23
20
|
import {
|
|
24
21
|
redactSecrets
|
|
25
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-3KFLQE6Y.js";
|
|
26
23
|
import {
|
|
27
24
|
formatHitlSummary,
|
|
28
25
|
hitlExitCode
|
|
29
26
|
} from "./chunk-P7732A25.js";
|
|
27
|
+
import {
|
|
28
|
+
ensurePathIgnored
|
|
29
|
+
} from "./chunk-TTUFIE26.js";
|
|
30
30
|
|
|
31
31
|
// src/plan-loop/review-job.ts
|
|
32
32
|
import { randomBytes } from "crypto";
|
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
import { mkdir, writeFile } from "fs/promises";
|
|
3
3
|
import path from "path";
|
|
4
4
|
var HANDOFF_REL = ".cursor/HANDOFF.md";
|
|
5
|
+
var SKILL_DIRS_REL = [
|
|
6
|
+
".cursor/skills/core",
|
|
7
|
+
".cursor/skills/domain",
|
|
8
|
+
".cursor/skills/community"
|
|
9
|
+
];
|
|
5
10
|
var STATE_ROOT_ENV = "AGENT_KIT_STATE_ROOT";
|
|
6
11
|
var STATE_ROOT_DIRS = [".cursor", ".agent-kit"];
|
|
7
12
|
function resolveStateDir(env = process.env) {
|
|
@@ -32,6 +37,7 @@ async function ensureLoopLogsDir(paths) {
|
|
|
32
37
|
|
|
33
38
|
export {
|
|
34
39
|
HANDOFF_REL,
|
|
40
|
+
SKILL_DIRS_REL,
|
|
35
41
|
STATE_ROOT_ENV,
|
|
36
42
|
runnerStatePaths,
|
|
37
43
|
ensureLoopLogsDir
|
|
@@ -4,11 +4,11 @@ import {
|
|
|
4
4
|
RESOLVE_AGENT_KIT_REL,
|
|
5
5
|
SESSION_START_HOOK_MARKER,
|
|
6
6
|
mergeAllowRowsWithoutGuard
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-BVZDPVUL.js";
|
|
8
8
|
import {
|
|
9
9
|
CLAUDE_COMMANDS_DIR_REL,
|
|
10
10
|
discoverInstalledCommands
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-FUSNEYGU.js";
|
|
12
12
|
import {
|
|
13
13
|
findOnPath
|
|
14
14
|
} from "./chunk-WGLPZXNU.js";
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
formatStaleCliRefusal,
|
|
7
7
|
installL0,
|
|
8
8
|
syncFromManifest
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-2GXN7HVG.js";
|
|
10
10
|
import {
|
|
11
11
|
SkippedSymlinkError,
|
|
12
12
|
formatPersonalizationSkippedSymlinks,
|
|
@@ -15,25 +15,25 @@ import {
|
|
|
15
15
|
import {
|
|
16
16
|
REGISTRY_CLI_ARGS,
|
|
17
17
|
resolveRegistryFromCli
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-SWJJW624.js";
|
|
19
19
|
import {
|
|
20
20
|
assessClaudeCommandAdapters,
|
|
21
21
|
executeSafeReadinessFixes
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-PCIYXGB3.js";
|
|
23
23
|
import {
|
|
24
24
|
cachedCliNpmLatest,
|
|
25
25
|
writeReadinessSnapshot
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-FB6G6OD6.js";
|
|
27
27
|
import {
|
|
28
28
|
writeClaudeSessionStartHook
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-BVZDPVUL.js";
|
|
30
30
|
import {
|
|
31
31
|
CLAUDE_HITL_FALLBACK,
|
|
32
32
|
generateClaudeCommandAdapters
|
|
33
|
-
} from "./chunk-
|
|
33
|
+
} from "./chunk-FUSNEYGU.js";
|
|
34
34
|
import {
|
|
35
35
|
feedInstallsRegistry
|
|
36
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-NHJ4IAVN.js";
|
|
37
37
|
import {
|
|
38
38
|
shouldUseWelcomeColor,
|
|
39
39
|
withCliProgress
|
|
@@ -62,13 +62,13 @@ import {
|
|
|
62
62
|
npxPinned,
|
|
63
63
|
pathCliStatus,
|
|
64
64
|
syncPathCliToRuntime
|
|
65
|
-
} from "./chunk-
|
|
65
|
+
} from "./chunk-RRJVC35Y.js";
|
|
66
66
|
import {
|
|
67
67
|
assessEnvironment
|
|
68
68
|
} from "./chunk-2TW7ENWC.js";
|
|
69
69
|
import {
|
|
70
70
|
warnIfRunningCliBehindNpm
|
|
71
|
-
} from "./chunk-
|
|
71
|
+
} from "./chunk-Y5526WCN.js";
|
|
72
72
|
import {
|
|
73
73
|
UnknownPackError,
|
|
74
74
|
allPacks,
|
|
@@ -88,14 +88,14 @@ import {
|
|
|
88
88
|
resolveProtectedGlobs,
|
|
89
89
|
saveManifest,
|
|
90
90
|
skillTargetDir
|
|
91
|
-
} from "./chunk-
|
|
91
|
+
} from "./chunk-ZNZHDPS3.js";
|
|
92
92
|
import {
|
|
93
93
|
DOMAIN_PACK_IDS
|
|
94
|
-
} from "./chunk-
|
|
94
|
+
} from "./chunk-KMK4T4ZM.js";
|
|
95
95
|
import {
|
|
96
96
|
KIT_VERSION,
|
|
97
97
|
pinnedCliSpec
|
|
98
|
-
} from "./chunk-
|
|
98
|
+
} from "./chunk-2G4K4ZI5.js";
|
|
99
99
|
import {
|
|
100
100
|
ensureDir,
|
|
101
101
|
fileExists,
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import {
|
|
2
|
-
ensurePathIgnored
|
|
3
|
-
} from "./chunk-MUTTNRX4.js";
|
|
4
1
|
import {
|
|
5
2
|
claudeRedactions,
|
|
6
3
|
redactSecrets
|
|
7
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-3KFLQE6Y.js";
|
|
8
5
|
import {
|
|
9
6
|
findHitlGateInText
|
|
10
7
|
} from "./chunk-P7732A25.js";
|
|
8
|
+
import {
|
|
9
|
+
ensurePathIgnored
|
|
10
|
+
} from "./chunk-TTUFIE26.js";
|
|
11
11
|
import {
|
|
12
12
|
findOnPath
|
|
13
13
|
} from "./chunk-WGLPZXNU.js";
|
|
@@ -496,7 +496,12 @@ var KNOWN_SHIPPED_OVERLAY_HASHES = /* @__PURE__ */ new Set([
|
|
|
496
496
|
"ec8b8f4b3a12813a6cba9c5a417f5f1ef8ed34e27ea0c1cdc7d2987ce32e0d00",
|
|
497
497
|
"f0555c4a43c3cfd5e6c9fdc9ce14922aaf927d1251d98465f8bc50e6a992d547",
|
|
498
498
|
"9d419d86204df507806fb96dc9e2ba14335b11a1d1a584fbefb1bd31799f1edb",
|
|
499
|
-
"cb7dc49acdf3d4bcce0fc6df938fe6f7867ee548147049cae840d92759a7e665"
|
|
499
|
+
"cb7dc49acdf3d4bcce0fc6df938fe6f7867ee548147049cae840d92759a7e665",
|
|
500
|
+
"3ac7992930166e8ffcfa648f01009e956bc6c6df49083c5f32a32e62186d16b7",
|
|
501
|
+
"5c91baae02679b8339f5347e038a1ee45fd785eec8ed5d1865b8139d88f53e74",
|
|
502
|
+
"5d8f9da50239efb7322d314ea2e6fae90e20942d0d4e325f35b7a59e4b2b8150",
|
|
503
|
+
"885ae1082642136b1324bf2d8b3bb9924eed693f10ec7b08e7a59c636d8d5007",
|
|
504
|
+
"eafbc96739f333138df4fbb2f1be8bd5b67681748ccbf02895f337b5edd29f37"
|
|
500
505
|
]);
|
|
501
506
|
|
|
502
507
|
// src/lifecycle/paths.ts
|
|
@@ -9,18 +9,19 @@ import {
|
|
|
9
9
|
cursorAcpBackend,
|
|
10
10
|
cursorAgentHeadlessArgs,
|
|
11
11
|
cursorAgentReviewArgs,
|
|
12
|
+
localBackend,
|
|
12
13
|
openrouterArgs,
|
|
13
14
|
redactSecrets,
|
|
14
15
|
resolveHitlRunOptions,
|
|
15
16
|
spawnLogged
|
|
16
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-3KFLQE6Y.js";
|
|
17
18
|
import {
|
|
18
19
|
RESERVED_GATE_IDS
|
|
19
20
|
} from "./chunk-P7732A25.js";
|
|
20
21
|
import {
|
|
21
22
|
ensureLoopLogsDir,
|
|
22
23
|
runnerStatePaths
|
|
23
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-O7VMHCNN.js";
|
|
24
25
|
import {
|
|
25
26
|
fileExists
|
|
26
27
|
} from "./chunk-5B4DVO6C.js";
|
|
@@ -158,6 +159,20 @@ async function runHeadlessDispatch(opts) {
|
|
|
158
159
|
onSpawn: opts.onSpawn
|
|
159
160
|
});
|
|
160
161
|
}
|
|
162
|
+
if (opts.backendId === "local") {
|
|
163
|
+
return localBackend.run({
|
|
164
|
+
workspace: opts.workspace,
|
|
165
|
+
prompt: opts.prompt,
|
|
166
|
+
model: opts.model,
|
|
167
|
+
logPath: opts.logPath,
|
|
168
|
+
spawnFn: opts.spawnFn,
|
|
169
|
+
log: opts.log,
|
|
170
|
+
hitl: opts.hitl,
|
|
171
|
+
render: opts.render,
|
|
172
|
+
onSpawn: opts.onSpawn,
|
|
173
|
+
...opts.onProgress ? { onProgress: opts.onProgress } : {}
|
|
174
|
+
});
|
|
175
|
+
}
|
|
161
176
|
if (opts.backendId === "openrouter") {
|
|
162
177
|
const log = opts.log ?? ((line) => console.log(line));
|
|
163
178
|
const env = claudeChildEnv();
|
|
@@ -4,14 +4,14 @@ import {
|
|
|
4
4
|
import {
|
|
5
5
|
compareSemver,
|
|
6
6
|
normalizeSemver
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-Y5526WCN.js";
|
|
8
8
|
import {
|
|
9
9
|
MANIFEST_RELATIVE_PATH
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-KMK4T4ZM.js";
|
|
11
11
|
import {
|
|
12
12
|
KIT_VERSION,
|
|
13
13
|
pinnedCliSpec
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-2G4K4ZI5.js";
|
|
15
15
|
import {
|
|
16
16
|
fileExists
|
|
17
17
|
} from "./chunk-5B4DVO6C.js";
|