@workit-dev/codex 2.20.4 → 2.20.6
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/.codex-plugin/plugin.json +1 -1
- package/dist/launch-mcp.js +31 -4
- package/dist/{workit-hook-vzz5v5cy.js → workit-hook-0fd33f54.js} +2 -2
- package/dist/{workit-hook-9k8dtngs.js → workit-hook-52cm7mqd.js} +2 -2
- package/dist/{workit-hook-zyj0kzc5.js → workit-hook-sdmcdyrk.js} +2 -2
- package/dist/{workit-hook-1xk8mx4h.js → workit-hook-ta5skes6.js} +1 -1
- package/dist/{workit-hook-wppqnbws.js → workit-hook-x482fqpj.js} +31 -4
- package/dist/{workit-hook-w7w0fe4v.js → workit-hook-xdv92sjp.js} +1 -1
- package/dist/workit-hook.js +5 -5
- package/package.json +3 -3
package/dist/launch-mcp.js
CHANGED
|
@@ -20334,6 +20334,8 @@ var GENERATED_GITIGNORES2 = new Set([`*
|
|
|
20334
20334
|
`, `*
|
|
20335
20335
|
!risk-paths
|
|
20336
20336
|
`]);
|
|
20337
|
+
var CHECK_HEAVY = [true, "io"];
|
|
20338
|
+
var CHECK_KEYS = ["command", "heavy"];
|
|
20337
20339
|
var isRecord2 = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
|
|
20338
20340
|
var SHELL_META = /[|&;<>()$`\\*?[\]{}~!#]/u;
|
|
20339
20341
|
function splitCommand(command) {
|
|
@@ -20530,10 +20532,10 @@ function loadCheckConfig(cwd) {
|
|
|
20530
20532
|
for (const [name, value] of Object.entries(parsed.checks)) {
|
|
20531
20533
|
if (!CHECK_NAME.test(name))
|
|
20532
20534
|
return none(`${label}: check name "${name}" must match ${CHECK_NAME.source}`);
|
|
20533
|
-
const
|
|
20534
|
-
if (
|
|
20535
|
-
return none(`${label}: check "${name}": ${
|
|
20536
|
-
checks.push({ name, argv, accepts: [argv] });
|
|
20535
|
+
const check = checkEntry(value);
|
|
20536
|
+
if (check instanceof Error)
|
|
20537
|
+
return none(`${label}: check "${name}": ${check.message}`);
|
|
20538
|
+
checks.push({ name, argv: check.argv, accepts: [check.argv], ...check.heavy });
|
|
20537
20539
|
}
|
|
20538
20540
|
const gates = {};
|
|
20539
20541
|
if (parsed.gates !== undefined) {
|
|
@@ -20577,6 +20579,31 @@ function loadCheckConfig(cwd) {
|
|
|
20577
20579
|
regenerable
|
|
20578
20580
|
};
|
|
20579
20581
|
}
|
|
20582
|
+
function commandArgv(value) {
|
|
20583
|
+
if (typeof value === "string")
|
|
20584
|
+
return splitCommand(value);
|
|
20585
|
+
return Array.isArray(value) && value.length > 0 && value.every((item) => typeof item === "string" && item.length > 0) ? value : new Error("expected a command string or a non-empty argv array");
|
|
20586
|
+
}
|
|
20587
|
+
function checkEntry(value) {
|
|
20588
|
+
if (!isRecord2(value)) {
|
|
20589
|
+
const argv = commandArgv(value);
|
|
20590
|
+
return argv instanceof Error ? argv : { argv, heavy: {} };
|
|
20591
|
+
}
|
|
20592
|
+
const unknown = Object.keys(value).find((key) => !CHECK_KEYS.includes(key));
|
|
20593
|
+
if (unknown)
|
|
20594
|
+
return new Error(`"${unknown}" is not a check setting (use ${CHECK_KEYS.join(" or ")})`);
|
|
20595
|
+
if (value.command === undefined)
|
|
20596
|
+
return new Error('needs "command": a command string or a non-empty argv array');
|
|
20597
|
+
const argv = commandArgv(value.command);
|
|
20598
|
+
if (argv instanceof Error)
|
|
20599
|
+
return new Error(`command: ${argv.message}`);
|
|
20600
|
+
if (value.heavy === undefined)
|
|
20601
|
+
return { argv, heavy: {} };
|
|
20602
|
+
const heavy = CHECK_HEAVY.find((allowed) => allowed === value.heavy);
|
|
20603
|
+
if (heavy === undefined)
|
|
20604
|
+
return new Error(`heavy must be ${CHECK_HEAVY.map((allowed) => JSON.stringify(allowed)).join(" or ")}, not ${JSON.stringify(value.heavy)}`);
|
|
20605
|
+
return { argv, heavy: { heavy } };
|
|
20606
|
+
}
|
|
20580
20607
|
var sameArgv = (left, right) => left.length === right.length && left.every((item, index) => item === right[index]);
|
|
20581
20608
|
function matchesNamedCheck(config, name, argv, cwd) {
|
|
20582
20609
|
if (config.error || name === null || cwd !== ".")
|
|
@@ -16,7 +16,7 @@ import {
|
|
|
16
16
|
checkCommand,
|
|
17
17
|
lightCommand,
|
|
18
18
|
maybeHeavy2
|
|
19
|
-
} from "./workit-hook-
|
|
19
|
+
} from "./workit-hook-x482fqpj.js";
|
|
20
20
|
import {
|
|
21
21
|
gitStoreDir2,
|
|
22
22
|
standingSeenFile2,
|
|
@@ -32,7 +32,7 @@ import {
|
|
|
32
32
|
} from "./workit-hook-azjr1ew1.js";
|
|
33
33
|
import {
|
|
34
34
|
recordHookRun2
|
|
35
|
-
} from "./workit-hook-
|
|
35
|
+
} from "./workit-hook-xdv92sjp.js";
|
|
36
36
|
import {
|
|
37
37
|
budgetHooks2
|
|
38
38
|
} from "./workit-hook-b8nrcfzr.js";
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
import {
|
|
3
3
|
stateDir3
|
|
4
4
|
} from "./workit-hook-7jv519ep.js";
|
|
5
|
-
import"./workit-hook-
|
|
5
|
+
import"./workit-hook-x482fqpj.js";
|
|
6
6
|
import {
|
|
7
7
|
recordHookFailure2
|
|
8
|
-
} from "./workit-hook-
|
|
8
|
+
} from "./workit-hook-xdv92sjp.js";
|
|
9
9
|
|
|
10
10
|
// packages/workit-core/src/core/node-resolve.mjs
|
|
11
11
|
import { spawnSync } from "node:child_process";
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
import {
|
|
3
3
|
recordHookRun2,
|
|
4
4
|
recordHookFailure2
|
|
5
|
-
} from "./workit-hook-
|
|
6
|
-
import"./workit-hook-
|
|
5
|
+
} from "./workit-hook-xdv92sjp.js";
|
|
6
|
+
import"./workit-hook-x482fqpj.js";
|
|
7
7
|
import"./workit-hook-7jv519ep.js";
|
|
8
8
|
export {
|
|
9
9
|
recordHookFailure2 as recordHookFailure,
|
|
@@ -122,6 +122,8 @@ function repoHeavyCommands(root) {
|
|
|
122
122
|
return [];
|
|
123
123
|
}
|
|
124
124
|
}
|
|
125
|
+
var CHECK_HEAVY = [true, "io"];
|
|
126
|
+
var CHECK_KEYS = ["command", "heavy"];
|
|
125
127
|
var isRecord = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
|
|
126
128
|
var SHELL_META = /[|&;<>()$`\\*?[\]{}~!#]/u;
|
|
127
129
|
function splitCommand(command) {
|
|
@@ -318,10 +320,10 @@ function loadCheckConfig(cwd) {
|
|
|
318
320
|
for (const [name, value] of Object.entries(parsed.checks)) {
|
|
319
321
|
if (!CHECK_NAME.test(name))
|
|
320
322
|
return none(`${label}: check name "${name}" must match ${CHECK_NAME.source}`);
|
|
321
|
-
const
|
|
322
|
-
if (
|
|
323
|
-
return none(`${label}: check "${name}": ${
|
|
324
|
-
checks.push({ name, argv, accepts: [argv] });
|
|
323
|
+
const check = checkEntry(value);
|
|
324
|
+
if (check instanceof Error)
|
|
325
|
+
return none(`${label}: check "${name}": ${check.message}`);
|
|
326
|
+
checks.push({ name, argv: check.argv, accepts: [check.argv], ...check.heavy });
|
|
325
327
|
}
|
|
326
328
|
const gates = {};
|
|
327
329
|
if (parsed.gates !== undefined) {
|
|
@@ -365,6 +367,31 @@ function loadCheckConfig(cwd) {
|
|
|
365
367
|
regenerable
|
|
366
368
|
};
|
|
367
369
|
}
|
|
370
|
+
function commandArgv(value) {
|
|
371
|
+
if (typeof value === "string")
|
|
372
|
+
return splitCommand(value);
|
|
373
|
+
return Array.isArray(value) && value.length > 0 && value.every((item) => typeof item === "string" && item.length > 0) ? value : new Error("expected a command string or a non-empty argv array");
|
|
374
|
+
}
|
|
375
|
+
function checkEntry(value) {
|
|
376
|
+
if (!isRecord(value)) {
|
|
377
|
+
const argv = commandArgv(value);
|
|
378
|
+
return argv instanceof Error ? argv : { argv, heavy: {} };
|
|
379
|
+
}
|
|
380
|
+
const unknown = Object.keys(value).find((key) => !CHECK_KEYS.includes(key));
|
|
381
|
+
if (unknown)
|
|
382
|
+
return new Error(`"${unknown}" is not a check setting (use ${CHECK_KEYS.join(" or ")})`);
|
|
383
|
+
if (value.command === undefined)
|
|
384
|
+
return new Error('needs "command": a command string or a non-empty argv array');
|
|
385
|
+
const argv = commandArgv(value.command);
|
|
386
|
+
if (argv instanceof Error)
|
|
387
|
+
return new Error(`command: ${argv.message}`);
|
|
388
|
+
if (value.heavy === undefined)
|
|
389
|
+
return { argv, heavy: {} };
|
|
390
|
+
const heavy = CHECK_HEAVY.find((allowed) => allowed === value.heavy);
|
|
391
|
+
if (heavy === undefined)
|
|
392
|
+
return new Error(`heavy must be ${CHECK_HEAVY.map((allowed) => JSON.stringify(allowed)).join(" or ")}, not ${JSON.stringify(value.heavy)}`);
|
|
393
|
+
return { argv, heavy: { heavy } };
|
|
394
|
+
}
|
|
368
395
|
var sameArgv = (left, right) => left.length === right.length && left.every((item, index) => item === right[index]);
|
|
369
396
|
function matchesNamedCheck(config, name, argv, cwd) {
|
|
370
397
|
if (config.error || name === null || cwd !== ".")
|
package/dist/workit-hook.js
CHANGED
|
@@ -29,16 +29,16 @@ var nodeFloor = () => {
|
|
|
29
29
|
var codexHost = () => process.env.CODEX_INTERNAL_ORIGINATOR_OVERRIDE === "Codex Desktop" || process.env.CODEX_ELECTRON_RESOURCES_PATH ? "codex_desktop" : "codex_cli";
|
|
30
30
|
var tooOld = nodeFloor();
|
|
31
31
|
if (tooOld) {
|
|
32
|
-
const { belowFloor } = await import("./workit-hook-
|
|
32
|
+
const { belowFloor } = await import("./workit-hook-52cm7mqd.js");
|
|
33
33
|
process.exit(await belowFloor(codexHost(), { ...tooOld, found: foundNode }, fileURLToPath(import.meta.url)));
|
|
34
34
|
}
|
|
35
35
|
var { useOwnedWorkitCli } = await import("./workit-hook-dzfxvq92.js");
|
|
36
36
|
useOwnedWorkitCli();
|
|
37
|
-
var { maybeHeavy, stateDir } = await import("./workit-hook-
|
|
37
|
+
var { maybeHeavy, stateDir } = await import("./workit-hook-ta5skes6.js");
|
|
38
38
|
var { configDir } = await import("./workit-hook-z09frbdk.js");
|
|
39
39
|
var { standingPending } = await import("./workit-hook-mk64s4fk.js");
|
|
40
40
|
var { procNoticeFile } = await import("./workit-hook-vmvv43m0.js");
|
|
41
|
-
var { recordHookRun } = await import("./workit-hook-
|
|
41
|
+
var { recordHookRun } = await import("./workit-hook-sdmcdyrk.js");
|
|
42
42
|
var { observeHookBudget } = await import("./workit-hook-3g6cv3hd.js");
|
|
43
43
|
var { hasTaskStore, mayReach } = await import("./workit-hook-7dwf87hc.js");
|
|
44
44
|
var YTRACK_WORD = /ytrack(?![\w/-]|\.(?!exe|cmd))/i;
|
|
@@ -101,10 +101,10 @@ if (quiet) {
|
|
|
101
101
|
`);
|
|
102
102
|
} else {
|
|
103
103
|
try {
|
|
104
|
-
const { runCodexHook } = await import("./workit-hook-
|
|
104
|
+
const { runCodexHook } = await import("./workit-hook-0fd33f54.js");
|
|
105
105
|
await runCodexHook([payload]);
|
|
106
106
|
} catch (error) {
|
|
107
|
-
const { answerRuntimeFailure } = await import("./workit-hook-
|
|
107
|
+
const { answerRuntimeFailure } = await import("./workit-hook-52cm7mqd.js");
|
|
108
108
|
answerRuntimeFailure(codexHost(), payload, error);
|
|
109
109
|
process.exitCode = 0;
|
|
110
110
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@workit-dev/codex",
|
|
3
|
-
"version": "2.20.
|
|
3
|
+
"version": "2.20.6",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Workit Codex CLI/desktop plugin — shared MCP transport, hooks, method skills, and verifier/reviewer/implementer agents",
|
|
6
6
|
"keywords": [
|
|
@@ -41,8 +41,8 @@
|
|
|
41
41
|
"build": "bun scripts/build.ts"
|
|
42
42
|
},
|
|
43
43
|
"devDependencies": {
|
|
44
|
-
"@workit-dev/core": "^2.20.
|
|
45
|
-
"@workit-dev/mcp": "^2.20.
|
|
44
|
+
"@workit-dev/core": "^2.20.6",
|
|
45
|
+
"@workit-dev/mcp": "^2.20.6"
|
|
46
46
|
},
|
|
47
47
|
"engines": {
|
|
48
48
|
"node": ">=24"
|