lazycodex-ai 5.1.1 → 5.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.ja.md +3 -3
- package/README.ko.md +3 -3
- package/README.md +6 -4
- package/README.ru.md +3 -3
- package/README.zh-cn.md +3 -3
- package/dist/cli/index.js +112 -95
- package/dist/cli-node/index.js +112 -95
- package/package.json +1 -5
- package/packages/omo-codex/plugin/.codex-plugin/plugin.json +1 -1
- package/packages/omo-codex/plugin/components/bootstrap/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/bootstrap/package.json +1 -1
- package/packages/omo-codex/plugin/components/comment-checker/dist/cli.js +33 -7
- package/packages/omo-codex/plugin/components/comment-checker/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/comment-checker/package.json +1 -1
- package/packages/omo-codex/plugin/components/comment-checker/src/runner.ts +4 -4
- package/packages/omo-codex/plugin/components/git-bash/hooks/hooks.json +2 -2
- package/packages/omo-codex/plugin/components/git-bash/package.json +1 -1
- package/packages/omo-codex/plugin/components/lazycodex-executor-verify/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/lazycodex-executor-verify/package.json +1 -1
- package/packages/omo-codex/plugin/components/lsp/dist/.omo-runtime-manifest.json +2 -2
- package/packages/omo-codex/plugin/components/lsp/hooks/hooks.json +2 -2
- package/packages/omo-codex/plugin/components/lsp/package.json +1 -1
- package/packages/omo-codex/plugin/components/rules/hooks/hooks.json +4 -4
- package/packages/omo-codex/plugin/components/rules/package.json +1 -1
- package/packages/omo-codex/plugin/components/teammode/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/teammode/package.json +1 -1
- package/packages/omo-codex/plugin/components/telemetry/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/telemetry/package.json +1 -1
- package/packages/omo-codex/plugin/components/ultrawork/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/ultrawork/package.json +1 -1
- package/packages/omo-codex/plugin/components/ulw-execute-continuation/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/ulw-execute-continuation/package.json +1 -1
- package/packages/omo-codex/plugin/components/ulw-loop/hooks/hooks.json +5 -5
- package/packages/omo-codex/plugin/components/ulw-loop/package.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-compact-resetting-git-bash-mcp-reminder.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-compact-resetting-lsp-diagnostics-cache.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-compact-resetting-project-rule-cache.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-checking-comments.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-checking-lsp-diagnostics.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-checking-thread-title-hygiene.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-matching-project-rules.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-recording-spawn-admission.json +1 -1
- package/packages/omo-codex/plugin/hooks/pre-tool-use-enforcing-unlimited-goal-budget.json +1 -1
- package/packages/omo-codex/plugin/hooks/pre-tool-use-guarding-ulw-loop-spawns.json +1 -1
- package/packages/omo-codex/plugin/hooks/pre-tool-use-recommending-git-bash-mcp.json +1 -1
- package/packages/omo-codex/plugin/hooks/session-start-checking-auto-update.json +1 -1
- package/packages/omo-codex/plugin/hooks/session-start-checking-bootstrap-provisioning.json +1 -1
- package/packages/omo-codex/plugin/hooks/session-start-loading-project-rules.json +1 -1
- package/packages/omo-codex/plugin/hooks/session-start-recording-session-telemetry.json +1 -1
- package/packages/omo-codex/plugin/hooks/stop-checking-ulw-execute-continuation.json +1 -1
- package/packages/omo-codex/plugin/hooks/stop-checking-ulw-loop-resume.json +1 -1
- package/packages/omo-codex/plugin/hooks/subagent-stop-verifying-lazycodex-executor-evidence.json +1 -1
- package/packages/omo-codex/plugin/hooks/user-prompt-submit-checking-ultrawork-trigger.json +1 -1
- package/packages/omo-codex/plugin/hooks/user-prompt-submit-checking-ulw-loop-steering.json +1 -1
- package/packages/omo-codex/plugin/hooks/user-prompt-submit-loading-project-rules.json +1 -1
- package/packages/omo-codex/plugin/package-lock.json +12 -12
- package/packages/omo-codex/plugin/package.json +1 -1
- package/packages/omo-codex/plugin/skills/browser/runtime/omowright/manifest.json +1 -1
- package/packages/omo-codex/plugin/skills/refactor/SKILL.md +1 -0
- package/packages/omo-codex/plugin/skills/remove-ai-slops/SKILL.md +1 -0
- package/packages/omo-codex/plugin/skills/ulw-execute/SKILL.md +1 -0
- package/packages/omo-codex/scripts/install-dist/install-local.mjs +2 -2
- package/packages/shared-skills/skills/browser/runtime/omowright/manifest.json +1 -1
- package/packages/shared-skills/skills/refactor/SKILL.md +1 -0
- package/packages/shared-skills/skills/remove-ai-slops/SKILL.md +1 -0
- package/packages/shared-skills/skills/ulw-execute/SKILL.md +1 -0
package/dist/cli-node/index.js
CHANGED
|
@@ -65,7 +65,7 @@ var package_default;
|
|
|
65
65
|
var init_package = __esm(() => {
|
|
66
66
|
package_default = {
|
|
67
67
|
name: "oh-my-opencode",
|
|
68
|
-
version: "5.1.
|
|
68
|
+
version: "5.1.3",
|
|
69
69
|
description: "The Best AI Agent Harness - Batteries-Included OpenCode Plugin with Multi-Model Orchestration, Parallel Background Agents, and Crafted LSP/AST Tools",
|
|
70
70
|
main: "./dist/index.js",
|
|
71
71
|
types: "dist/index.d.ts",
|
|
@@ -236,25 +236,14 @@ var init_package = __esm(() => {
|
|
|
236
236
|
},
|
|
237
237
|
homepage: "https://github.com/code-yeongyu/oh-my-openagent#readme",
|
|
238
238
|
dependencies: {
|
|
239
|
-
"@clack/prompts": "^1.8.1",
|
|
240
|
-
"@modelcontextprotocol/sdk": "^1.30.0",
|
|
241
|
-
"@opencode-ai/plugin": "1.18.31",
|
|
242
|
-
"@opencode-ai/sdk": "1.18.31",
|
|
243
|
-
"@opentui/core": "^0.5.11",
|
|
244
|
-
"@opentui/keymap": "^0.5.11",
|
|
245
239
|
"@opentui/solid": "^0.5.11",
|
|
246
|
-
commander: "^15.0.0",
|
|
247
240
|
"detect-libc": "^2.1.2",
|
|
248
|
-
diff: "^9.0.0",
|
|
249
|
-
"js-yaml": "^5.4.2",
|
|
250
|
-
"jsonc-parser": "^3.3.1",
|
|
251
|
-
picocolors: "^1.1.1",
|
|
252
|
-
picomatch: "^4.0.7",
|
|
253
|
-
"posthog-node": "^5.52.4",
|
|
254
241
|
zod: "^4.6.5"
|
|
255
242
|
},
|
|
256
243
|
devDependencies: {
|
|
257
|
-
"@
|
|
244
|
+
"@clack/prompts": "^1.8.1",
|
|
245
|
+
"@code-yeongyu/senpi": "2026.9.29-4",
|
|
246
|
+
"@modelcontextprotocol/sdk": "^1.30.0",
|
|
258
247
|
"@oh-my-opencode/agents-md-core": "workspace:*",
|
|
259
248
|
"@oh-my-opencode/ast-grep-mcp": "workspace:*",
|
|
260
249
|
"@oh-my-opencode/boulder-state": "workspace:*",
|
|
@@ -288,36 +277,43 @@ var init_package = __esm(() => {
|
|
|
288
277
|
"@oh-my-opencode/telemetry-core": "workspace:*",
|
|
289
278
|
"@oh-my-opencode/tmux-core": "workspace:*",
|
|
290
279
|
"@oh-my-opencode/utils": "workspace:*",
|
|
280
|
+
"@opencode-ai/plugin": "1.18.31",
|
|
281
|
+
"@opencode-ai/sdk": "1.18.31",
|
|
282
|
+
"@opentui/core": "^0.5.11",
|
|
283
|
+
"@opentui/keymap": "^0.5.11",
|
|
291
284
|
"@types/js-yaml": "^4.0.9",
|
|
292
285
|
"@types/picomatch": "^4.0.3",
|
|
293
286
|
"@typescript/native-preview": "7.0.0-dev.20260707.2",
|
|
294
287
|
"@xterm/addon-unicode11": "^0.9.0",
|
|
295
288
|
"@xterm/xterm": "^6.0.0",
|
|
296
289
|
"bun-types": "1.4.2",
|
|
290
|
+
commander: "^15.0.0",
|
|
291
|
+
diff: "^9.0.0",
|
|
292
|
+
"js-yaml": "^5.4.2",
|
|
293
|
+
"jsonc-parser": "^3.3.1",
|
|
297
294
|
"node-pty": "^1.1.0",
|
|
298
295
|
omowright: "github:code-yeongyu/omowright#293ca5002cbd4c8b0c104c5934683385ef7e0d3a",
|
|
296
|
+
picocolors: "^1.1.1",
|
|
297
|
+
picomatch: "^4.0.7",
|
|
298
|
+
"posthog-node": "^5.52.4",
|
|
299
299
|
"puppeteer-core": "^25.11.0",
|
|
300
300
|
typescript: "^7.0.2"
|
|
301
301
|
},
|
|
302
302
|
optionalDependencies: {
|
|
303
|
-
"oh-my-opencode-darwin-arm64": "5.1.
|
|
304
|
-
"oh-my-opencode-darwin-x64": "5.1.
|
|
305
|
-
"oh-my-opencode-darwin-x64-baseline": "5.1.
|
|
306
|
-
"oh-my-opencode-linux-arm64": "5.1.
|
|
307
|
-
"oh-my-opencode-linux-arm64-musl": "5.1.
|
|
308
|
-
"oh-my-opencode-linux-x64": "5.1.
|
|
309
|
-
"oh-my-opencode-linux-x64-baseline": "5.1.
|
|
310
|
-
"oh-my-opencode-linux-x64-musl": "5.1.
|
|
311
|
-
"oh-my-opencode-linux-x64-musl-baseline": "5.1.
|
|
312
|
-
"oh-my-opencode-windows-arm64": "5.1.
|
|
313
|
-
"oh-my-opencode-windows-x64": "5.1.
|
|
314
|
-
"oh-my-opencode-windows-x64-baseline": "5.1.
|
|
303
|
+
"oh-my-opencode-darwin-arm64": "5.1.3",
|
|
304
|
+
"oh-my-opencode-darwin-x64": "5.1.3",
|
|
305
|
+
"oh-my-opencode-darwin-x64-baseline": "5.1.3",
|
|
306
|
+
"oh-my-opencode-linux-arm64": "5.1.3",
|
|
307
|
+
"oh-my-opencode-linux-arm64-musl": "5.1.3",
|
|
308
|
+
"oh-my-opencode-linux-x64": "5.1.3",
|
|
309
|
+
"oh-my-opencode-linux-x64-baseline": "5.1.3",
|
|
310
|
+
"oh-my-opencode-linux-x64-musl": "5.1.3",
|
|
311
|
+
"oh-my-opencode-linux-x64-musl-baseline": "5.1.3",
|
|
312
|
+
"oh-my-opencode-windows-arm64": "5.1.3",
|
|
313
|
+
"oh-my-opencode-windows-x64": "5.1.3",
|
|
314
|
+
"oh-my-opencode-windows-x64-baseline": "5.1.3"
|
|
315
315
|
},
|
|
316
316
|
overrides: {
|
|
317
|
-
"@earendil-works/pi-agent-core": "0.84.2",
|
|
318
|
-
"@earendil-works/pi-ai": "0.84.2",
|
|
319
|
-
"@earendil-works/pi-coding-agent": "0.84.2",
|
|
320
|
-
"@earendil-works/pi-tui": "0.84.2",
|
|
321
317
|
hono: "^4.13.8",
|
|
322
318
|
"@hono/node-server": "2.1.1",
|
|
323
319
|
"express-rate-limit": "^8.7.0",
|
|
@@ -89103,7 +89099,7 @@ var package_default2;
|
|
|
89103
89099
|
var init_package2 = __esm(() => {
|
|
89104
89100
|
package_default2 = {
|
|
89105
89101
|
name: "@oh-my-opencode/omo-codex",
|
|
89106
|
-
version: "5.1.
|
|
89102
|
+
version: "5.1.3",
|
|
89107
89103
|
type: "module",
|
|
89108
89104
|
private: true,
|
|
89109
89105
|
description: "Codex harness adapter for oh-my-openagent. Vendored Codex plugin namespace (omo) + TypeScript installer + telemetry.",
|
|
@@ -106536,15 +106532,10 @@ async function checkDeprecatedReasoningKeys() {
|
|
|
106536
106532
|
}
|
|
106537
106533
|
|
|
106538
106534
|
// packages/omo-opencode/src/cli/doctor/checks/dependencies.ts
|
|
106539
|
-
init_src();
|
|
106540
106535
|
import { existsSync as existsSync55 } from "node:fs";
|
|
106541
|
-
import { createRequire as
|
|
106536
|
+
import { createRequire as createRequire4 } from "node:module";
|
|
106542
106537
|
import { homedir as homedir20 } from "node:os";
|
|
106543
|
-
import {
|
|
106544
|
-
|
|
106545
|
-
// packages/omo-opencode/src/hooks/comment-checker/downloader.ts
|
|
106546
|
-
import { join as join87 } from "path";
|
|
106547
|
-
import { homedir as homedir19, tmpdir as tmpdir4 } from "os";
|
|
106538
|
+
import { join as join89 } from "node:path";
|
|
106548
106539
|
// packages/comment-checker-core/src/release.ts
|
|
106549
106540
|
import { join as join85 } from "node:path";
|
|
106550
106541
|
var COMMENT_CHECKER_RELEASE_VERSION = "0.8.0";
|
|
@@ -106571,12 +106562,45 @@ function isCachedCommentCheckerCurrent(cacheDir, readFile = (path) => readFileSy
|
|
|
106571
106562
|
return false;
|
|
106572
106563
|
}
|
|
106573
106564
|
}
|
|
106565
|
+
// packages/comment-checker-core/src/package-binary.ts
|
|
106566
|
+
import { createRequire as createRequire3 } from "node:module";
|
|
106567
|
+
import { dirname as dirname33, join as join87 } from "node:path";
|
|
106568
|
+
var COMMENT_CHECKER_PACKAGE_NAME = "@code-yeongyu/comment-checker";
|
|
106569
|
+
function isModuleResolutionMiss(error) {
|
|
106570
|
+
return error instanceof Error || typeof error === "object" && error !== null && "name" in error && error.name === "ResolveMessage";
|
|
106571
|
+
}
|
|
106572
|
+
function findCommentCheckerPackageBinary(input) {
|
|
106573
|
+
const packageName = input.packageName ?? COMMENT_CHECKER_PACKAGE_NAME;
|
|
106574
|
+
const platformKey = `${input.platform ?? process.platform}-${input.arch ?? process.arch}`;
|
|
106575
|
+
const packageDir = dirname33(input.packageJsonPath);
|
|
106576
|
+
const candidates = [
|
|
106577
|
+
resolvePlatformPackageBinary(input.packageJsonPath, `${packageName}-${platformKey}`, input.binaryName),
|
|
106578
|
+
join87(packageDir, "vendor", platformKey, input.binaryName),
|
|
106579
|
+
join87(packageDir, "bin", input.binaryName)
|
|
106580
|
+
];
|
|
106581
|
+
return candidates.find((candidate) => candidate !== null && input.existsSync(candidate)) ?? null;
|
|
106582
|
+
}
|
|
106583
|
+
function resolvePlatformPackageBinary(packageJsonPath, platformPackageName, binaryName) {
|
|
106584
|
+
try {
|
|
106585
|
+
const manifestPath = createRequire3(packageJsonPath).resolve(`${platformPackageName}/package.json`);
|
|
106586
|
+
return join87(dirname33(manifestPath), "bin", binaryName);
|
|
106587
|
+
} catch (error) {
|
|
106588
|
+
if (isModuleResolutionMiss(error))
|
|
106589
|
+
return null;
|
|
106590
|
+
throw error;
|
|
106591
|
+
}
|
|
106592
|
+
}
|
|
106593
|
+
// packages/omo-opencode/src/cli/doctor/checks/dependencies.ts
|
|
106594
|
+
init_src();
|
|
106595
|
+
|
|
106574
106596
|
// packages/omo-opencode/src/hooks/comment-checker/downloader.ts
|
|
106597
|
+
import { join as join88 } from "path";
|
|
106598
|
+
import { homedir as homedir19, tmpdir as tmpdir4 } from "os";
|
|
106575
106599
|
init_binary_downloader();
|
|
106576
106600
|
init_logger2();
|
|
106577
106601
|
init_plugin_identity();
|
|
106578
106602
|
var DEBUG = process.env.COMMENT_CHECKER_DEBUG === "1";
|
|
106579
|
-
var DEBUG_FILE =
|
|
106603
|
+
var DEBUG_FILE = join88(tmpdir4(), "comment-checker-debug.log");
|
|
106580
106604
|
function getCacheDir2() {
|
|
106581
106605
|
return commentCheckerCacheDir({
|
|
106582
106606
|
platform: process.platform,
|
|
@@ -106635,7 +106659,7 @@ async function getBinaryVersion(binary) {
|
|
|
106635
106659
|
}
|
|
106636
106660
|
}
|
|
106637
106661
|
async function checkAstGrepCli() {
|
|
106638
|
-
const runtimeDir = astGrepRuntimeDir(
|
|
106662
|
+
const runtimeDir = astGrepRuntimeDir(join89(homedir20(), ".omo"));
|
|
106639
106663
|
const sgPath = findSgBinarySync({ runtimeDir });
|
|
106640
106664
|
if (sgPath === null) {
|
|
106641
106665
|
return {
|
|
@@ -106657,20 +106681,14 @@ async function checkAstGrepCli() {
|
|
|
106657
106681
|
};
|
|
106658
106682
|
}
|
|
106659
106683
|
function resolveCommentCheckerPackageJson() {
|
|
106660
|
-
const require2 =
|
|
106684
|
+
const require2 = createRequire4(import.meta.url);
|
|
106661
106685
|
return require2.resolve("@code-yeongyu/comment-checker/package.json");
|
|
106662
106686
|
}
|
|
106663
|
-
function
|
|
106687
|
+
function findCommentCheckerPackageBinary2(baseDirOverride, resolvePackageJsonPath = resolveCommentCheckerPackageJson) {
|
|
106664
106688
|
const binaryName = process.platform === "win32" ? "comment-checker.exe" : "comment-checker";
|
|
106665
|
-
const platformKey = `${process.platform}-${process.arch === "x64" ? "x64" : process.arch}`;
|
|
106666
106689
|
try {
|
|
106667
|
-
const
|
|
106668
|
-
|
|
106669
|
-
if (existsSync55(vendorPath))
|
|
106670
|
-
return vendorPath;
|
|
106671
|
-
const binPath = join88(packageDir, "bin", binaryName);
|
|
106672
|
-
if (existsSync55(binPath))
|
|
106673
|
-
return binPath;
|
|
106690
|
+
const packageJsonPath = baseDirOverride === undefined ? resolvePackageJsonPath() : join89(baseDirOverride, "package.json");
|
|
106691
|
+
return findCommentCheckerPackageBinary({ packageJsonPath, binaryName, existsSync: existsSync55 });
|
|
106674
106692
|
} catch (error) {
|
|
106675
106693
|
if (!(error instanceof Error) && !isModuleResolutionFailure(error))
|
|
106676
106694
|
throw error;
|
|
@@ -106690,7 +106708,7 @@ async function checkCommentChecker() {
|
|
|
106690
106708
|
};
|
|
106691
106709
|
}
|
|
106692
106710
|
const binaryCheck = await checkBinaryExists("comment-checker");
|
|
106693
|
-
const resolvedPath = binaryCheck.exists ? binaryCheck.path :
|
|
106711
|
+
const resolvedPath = binaryCheck.exists ? binaryCheck.path : findCommentCheckerPackageBinary2();
|
|
106694
106712
|
if (!resolvedPath) {
|
|
106695
106713
|
return {
|
|
106696
106714
|
name: "Comment Checker",
|
|
@@ -106816,7 +106834,7 @@ async function getGhCliInfo(dependencies = {}) {
|
|
|
106816
106834
|
init_zod();
|
|
106817
106835
|
init_opencode_config_dir();
|
|
106818
106836
|
import { existsSync as existsSync56, readFileSync as readFileSync38 } from "node:fs";
|
|
106819
|
-
import { delimiter as delimiter3, dirname as
|
|
106837
|
+
import { delimiter as delimiter3, dirname as dirname35, resolve as resolve23 } from "node:path";
|
|
106820
106838
|
import { fileURLToPath as fileURLToPath7 } from "node:url";
|
|
106821
106839
|
|
|
106822
106840
|
// packages/omo-opencode/src/mcp/cli-suffix.ts
|
|
@@ -106947,7 +106965,7 @@ var LSP_BOOTSTRAP_SCRIPT = [
|
|
|
106947
106965
|
].join(";");
|
|
106948
106966
|
function getModuleDirectory(moduleUrl) {
|
|
106949
106967
|
try {
|
|
106950
|
-
return
|
|
106968
|
+
return dirname35(fileURLToPath7(moduleUrl));
|
|
106951
106969
|
} catch (error) {
|
|
106952
106970
|
if (!(error instanceof Error))
|
|
106953
106971
|
throw error;
|
|
@@ -107044,13 +107062,13 @@ function getInstalledLspServers(options = {}) {
|
|
|
107044
107062
|
init_shared();
|
|
107045
107063
|
import { existsSync as existsSync57, readFileSync as readFileSync39 } from "node:fs";
|
|
107046
107064
|
import { homedir as homedir21 } from "node:os";
|
|
107047
|
-
import { join as
|
|
107065
|
+
import { join as join90 } from "node:path";
|
|
107048
107066
|
var BUILTIN_MCP_SERVERS = ["websearch", "context7", "grep_app", "lsp"];
|
|
107049
107067
|
function getMcpConfigPaths() {
|
|
107050
107068
|
return [
|
|
107051
|
-
|
|
107052
|
-
|
|
107053
|
-
|
|
107069
|
+
join90(homedir21(), ".claude", ".mcp.json"),
|
|
107070
|
+
join90(process.cwd(), ".mcp.json"),
|
|
107071
|
+
join90(process.cwd(), ".claude", ".mcp.json")
|
|
107054
107072
|
];
|
|
107055
107073
|
}
|
|
107056
107074
|
function loadUserMcpConfig() {
|
|
@@ -107332,7 +107350,7 @@ init_src();
|
|
|
107332
107350
|
import { existsSync as existsSync59 } from "node:fs";
|
|
107333
107351
|
import { lstat as lstat16, readdir as readdir14, readFile as readFile30 } from "node:fs/promises";
|
|
107334
107352
|
import { homedir as homedir23 } from "node:os";
|
|
107335
|
-
import { basename as basename12, join as
|
|
107353
|
+
import { basename as basename12, join as join91, resolve as resolve24 } from "node:path";
|
|
107336
107354
|
// packages/omo-opencode/package.json
|
|
107337
107355
|
var package_default3 = {
|
|
107338
107356
|
name: "@oh-my-opencode/omo-opencode",
|
|
@@ -107380,7 +107398,6 @@ var package_default3 = {
|
|
|
107380
107398
|
commander: "^15.0.0",
|
|
107381
107399
|
"jsonc-parser": "^3.3.1",
|
|
107382
107400
|
picocolors: "^1.1.1",
|
|
107383
|
-
picomatch: "^4.0.7",
|
|
107384
107401
|
zod: "^4.6.5"
|
|
107385
107402
|
}
|
|
107386
107403
|
};
|
|
@@ -107402,13 +107419,13 @@ var CODEX_BIN_NAMES = [
|
|
|
107402
107419
|
"omo-git-bash-hook"
|
|
107403
107420
|
];
|
|
107404
107421
|
async function gatherCodexSummary(deps = {}) {
|
|
107405
|
-
const codexHome = resolve24(deps.codexHome ?? process.env.CODEX_HOME ??
|
|
107422
|
+
const codexHome = resolve24(deps.codexHome ?? process.env.CODEX_HOME ?? join91(homedir23(), ".codex"));
|
|
107406
107423
|
const binDir = resolveCodexInstallerBinDir({ binDir: deps.binDir, codexHome, env: process.env });
|
|
107407
107424
|
const detection = await (deps.detectCodexInstallation ?? detectCodexInstallation)();
|
|
107408
107425
|
const pluginRoot = await resolveInstalledPluginRoot(codexHome);
|
|
107409
|
-
const manifest = pluginRoot === null ? null : await readJson(
|
|
107410
|
-
const installSnapshot = pluginRoot === null ? null : await readJson(
|
|
107411
|
-
const configPath =
|
|
107426
|
+
const manifest = pluginRoot === null ? null : await readJson(join91(pluginRoot, ".codex-plugin", "plugin.json"));
|
|
107427
|
+
const installSnapshot = pluginRoot === null ? null : await readJson(join91(pluginRoot, "lazycodex-install.json"));
|
|
107428
|
+
const configPath = join91(codexHome, "config.toml");
|
|
107412
107429
|
const pluginVersion = stringField(manifest, "version");
|
|
107413
107430
|
return {
|
|
107414
107431
|
codexPath: detection.found && "path" in detection ? detection.path : null,
|
|
@@ -107465,7 +107482,7 @@ function buildCodexIssues(summary) {
|
|
|
107465
107482
|
if (summary.pluginRoot === null) {
|
|
107466
107483
|
issues.push({
|
|
107467
107484
|
title: "OMO Codex plugin is not installed",
|
|
107468
|
-
description: `Expected cached plugin at ${
|
|
107485
|
+
description: `Expected cached plugin at ${join91("plugins", "cache", MARKETPLACE_NAME, PLUGIN_NAME2, DEFAULT_PLUGIN_VERSION)} under CODEX_HOME.`,
|
|
107469
107486
|
fix: "Run: npx lazycodex-ai install",
|
|
107470
107487
|
severity: "error",
|
|
107471
107488
|
affects: ["plugin loading"]
|
|
@@ -107530,12 +107547,12 @@ function buildCodexIssues(summary) {
|
|
|
107530
107547
|
return issues;
|
|
107531
107548
|
}
|
|
107532
107549
|
async function resolveInstalledPluginRoot(codexHome) {
|
|
107533
|
-
const pluginRoot =
|
|
107550
|
+
const pluginRoot = join91(codexHome, "plugins", "cache", MARKETPLACE_NAME, PLUGIN_NAME2);
|
|
107534
107551
|
if (!existsSync59(pluginRoot))
|
|
107535
107552
|
return null;
|
|
107536
107553
|
const versions = await readdir14(pluginRoot, { withFileTypes: true });
|
|
107537
107554
|
const candidates = versions.filter((entry) => entry.isDirectory()).map((entry) => entry.name).sort(compareVersionsDescending);
|
|
107538
|
-
return candidates.length === 0 ? null :
|
|
107555
|
+
return candidates.length === 0 ? null : join91(pluginRoot, candidates[0] ?? DEFAULT_PLUGIN_VERSION);
|
|
107539
107556
|
}
|
|
107540
107557
|
async function readCodexConfigSummary(configPath) {
|
|
107541
107558
|
if (!existsSync59(configPath)) {
|
|
@@ -107563,13 +107580,13 @@ async function readCodexConfigSummary(configPath) {
|
|
|
107563
107580
|
async function readLinkedBins(binDir) {
|
|
107564
107581
|
const linked = [];
|
|
107565
107582
|
for (const name of CODEX_BIN_NAMES) {
|
|
107566
|
-
if (await pathExists3(
|
|
107583
|
+
if (await pathExists3(join91(binDir, process.platform === "win32" ? `${name}.cmd` : name)))
|
|
107567
107584
|
linked.push(name);
|
|
107568
107585
|
}
|
|
107569
107586
|
return linked;
|
|
107570
107587
|
}
|
|
107571
107588
|
async function readLinkedAgents(codexHome) {
|
|
107572
|
-
const agentsDir =
|
|
107589
|
+
const agentsDir = join91(codexHome, "agents");
|
|
107573
107590
|
if (!existsSync59(agentsDir))
|
|
107574
107591
|
return [];
|
|
107575
107592
|
const entries = await readdir14(agentsDir, { withFileTypes: true });
|
|
@@ -107703,7 +107720,7 @@ function resolveLatestVersion(input) {
|
|
|
107703
107720
|
init_src();
|
|
107704
107721
|
import { readdir as readdir15, readFile as readFile31, stat as stat7 } from "node:fs/promises";
|
|
107705
107722
|
import { homedir as homedir24 } from "node:os";
|
|
107706
|
-
import { dirname as
|
|
107723
|
+
import { dirname as dirname36, isAbsolute as isAbsolute14, join as join92, relative as relative9, resolve as resolve25, sep as sep9 } from "node:path";
|
|
107707
107724
|
var CODEX_COMPONENTS_CHECK_ID = "codex-components";
|
|
107708
107725
|
var CODEX_COMPONENTS_CHECK_NAME = "codex-components";
|
|
107709
107726
|
var PLUGIN_DATA_DIR_NAME = "omo-sisyphuslabs";
|
|
@@ -107713,7 +107730,7 @@ async function checkCodexComponents(deps = {}) {
|
|
|
107713
107730
|
const env = deps.env ?? process.env;
|
|
107714
107731
|
const platform = deps.platform ?? process.platform;
|
|
107715
107732
|
const arch = deps.arch ?? process.arch;
|
|
107716
|
-
const codexHome = resolve25(deps.codexHome ?? env["CODEX_HOME"] ??
|
|
107733
|
+
const codexHome = resolve25(deps.codexHome ?? env["CODEX_HOME"] ?? join92(homedir24(), ".codex"));
|
|
107717
107734
|
const summary = await gatherCodexSummary({ ...deps, codexHome });
|
|
107718
107735
|
if (summary.pluginRoot === null) {
|
|
107719
107736
|
return {
|
|
@@ -107738,7 +107755,7 @@ async function checkCodexComponents(deps = {}) {
|
|
|
107738
107755
|
});
|
|
107739
107756
|
}
|
|
107740
107757
|
const runtimeSgDir = runtimeSgDirectory(codexHome, platform, arch);
|
|
107741
|
-
const runtimeSgPath =
|
|
107758
|
+
const runtimeSgPath = join92(runtimeSgDir, sgBinaryName(platform));
|
|
107742
107759
|
const sg = findSgBinarySync({
|
|
107743
107760
|
arch,
|
|
107744
107761
|
env,
|
|
@@ -107777,7 +107794,7 @@ async function auditBundleTargets(pluginRoot) {
|
|
|
107777
107794
|
const manifest = await readJson2(manifestPath);
|
|
107778
107795
|
if (manifest === null || !isRecord18(manifest["mcpServers"]))
|
|
107779
107796
|
continue;
|
|
107780
|
-
const manifestRoot =
|
|
107797
|
+
const manifestRoot = dirname36(manifestPath);
|
|
107781
107798
|
const isRootManifest = resolve25(manifestRoot) === resolve25(pluginRoot);
|
|
107782
107799
|
for (const server of Object.values(manifest["mcpServers"])) {
|
|
107783
107800
|
if (!isRecord18(server) || !Array.isArray(server["args"]))
|
|
@@ -107798,7 +107815,7 @@ async function auditBundleTargets(pluginRoot) {
|
|
|
107798
107815
|
continue;
|
|
107799
107816
|
const commands = [];
|
|
107800
107817
|
collectHookCommands(manifest, commands);
|
|
107801
|
-
const hookPluginRoot =
|
|
107818
|
+
const hookPluginRoot = dirname36(dirname36(hookManifestPath));
|
|
107802
107819
|
for (const command of commands) {
|
|
107803
107820
|
for (const relativePath of extractPluginRootPaths(command)) {
|
|
107804
107821
|
referencedCount += 1;
|
|
@@ -107837,7 +107854,7 @@ async function classifyBundleTarget(bundleRoot, baseRoot, relativePath, allowEsc
|
|
|
107837
107854
|
}
|
|
107838
107855
|
async function findHookManifestPaths(root) {
|
|
107839
107856
|
const paths = await findManifestPaths(root, "hooks.json");
|
|
107840
|
-
return paths.filter((path) =>
|
|
107857
|
+
return paths.filter((path) => dirname36(path).endsWith(`${sep9}hooks`));
|
|
107841
107858
|
}
|
|
107842
107859
|
async function findManifestPaths(root, manifestName) {
|
|
107843
107860
|
let entries;
|
|
@@ -107850,7 +107867,7 @@ async function findManifestPaths(root, manifestName) {
|
|
|
107850
107867
|
for (const entry of entries) {
|
|
107851
107868
|
if (entry.name === "node_modules" || entry.name === ".git")
|
|
107852
107869
|
continue;
|
|
107853
|
-
const entryPath =
|
|
107870
|
+
const entryPath = join92(root, entry.name);
|
|
107854
107871
|
if (entry.isDirectory()) {
|
|
107855
107872
|
paths.push(...await findManifestPaths(entryPath, manifestName));
|
|
107856
107873
|
continue;
|
|
@@ -107894,18 +107911,18 @@ function isPluginRuntimePathArg(arg) {
|
|
|
107894
107911
|
return normalized.endsWith(".js") && normalized.includes("/dist/") && (normalized.startsWith("./") || normalized.startsWith("../") || normalized.startsWith("components/") || normalized.startsWith("/") || isAbsolute14(arg));
|
|
107895
107912
|
}
|
|
107896
107913
|
function runtimeSgDirectory(codexHome, platform, arch) {
|
|
107897
|
-
return
|
|
107914
|
+
return join92(codexHome, "runtime", "ast-grep", runtimeSlug(platform, arch));
|
|
107898
107915
|
}
|
|
107899
107916
|
function describeSgSource(sgPath, env, runtimeSgDir, platform) {
|
|
107900
107917
|
const override = env[SG_PATH_ENV_KEY]?.trim();
|
|
107901
107918
|
if (override !== undefined && override.length > 0 && sgPath === override)
|
|
107902
107919
|
return `env override ${SG_PATH_ENV_KEY}`;
|
|
107903
|
-
if (sgPath ===
|
|
107920
|
+
if (sgPath === join92(runtimeSgDir, sgBinaryName(platform)))
|
|
107904
107921
|
return "runtime dir";
|
|
107905
107922
|
return "PATH";
|
|
107906
107923
|
}
|
|
107907
107924
|
async function readBootstrapStateSummary(codexHome) {
|
|
107908
|
-
const statePath =
|
|
107925
|
+
const statePath = join92(codexHome, "plugins", "data", PLUGIN_DATA_DIR_NAME, "bootstrap", "state.json");
|
|
107909
107926
|
const raw = await readJson2(statePath);
|
|
107910
107927
|
if (raw === null)
|
|
107911
107928
|
return null;
|
|
@@ -107984,16 +108001,16 @@ function isRecord18(value) {
|
|
|
107984
108001
|
import { existsSync as existsSync60 } from "node:fs";
|
|
107985
108002
|
import { readFile as readFile32 } from "node:fs/promises";
|
|
107986
108003
|
import { homedir as homedir25 } from "node:os";
|
|
107987
|
-
import { join as
|
|
108004
|
+
import { join as join93, resolve as resolve26 } from "node:path";
|
|
107988
108005
|
var RUNTIME_WRAPPER_MARKER2 = "OMO_GENERATED_RUNTIME_WRAPPER";
|
|
107989
108006
|
var CHECK_NAME = "codex-runtime-wrapper";
|
|
107990
108007
|
var REINSTALL_COMMAND = "npx --yes lazycodex-ai@latest install --no-tui";
|
|
107991
108008
|
async function checkCodexRuntimeWrapper(deps = {}) {
|
|
107992
|
-
const codexHome = resolve26(deps.codexHome ?? process.env.CODEX_HOME ??
|
|
108009
|
+
const codexHome = resolve26(deps.codexHome ?? process.env.CODEX_HOME ?? join93(homedir25(), ".codex"));
|
|
107993
108010
|
const binDir = resolveCodexInstallerBinDir({ binDir: deps.binDir, codexHome, env: process.env });
|
|
107994
108011
|
const platform = deps.platform ?? process.platform;
|
|
107995
|
-
const wrapperPath =
|
|
107996
|
-
const legacyWrapperPath =
|
|
108012
|
+
const wrapperPath = join93(binDir, platform === "win32" ? "omo-agent-toolkit.cmd" : "omo-agent-toolkit");
|
|
108013
|
+
const legacyWrapperPath = join93(binDir, platform === "win32" ? "omo.cmd" : "omo");
|
|
107997
108014
|
const [wrapper, legacyWrapper] = await Promise.all([readRuntimeWrapper(wrapperPath), readRuntimeWrapper(legacyWrapperPath)]);
|
|
107998
108015
|
const issues = [];
|
|
107999
108016
|
if (wrapper?.includes(RUNTIME_WRAPPER_MARKER2) === true) {
|
|
@@ -108529,12 +108546,12 @@ import {
|
|
|
108529
108546
|
unlinkSync as unlinkSync9,
|
|
108530
108547
|
writeFileSync as writeFileSync14
|
|
108531
108548
|
} from "node:fs";
|
|
108532
|
-
import { basename as basename13, dirname as
|
|
108549
|
+
import { basename as basename13, dirname as dirname37, join as join96 } from "node:path";
|
|
108533
108550
|
|
|
108534
108551
|
// packages/mcp-client-core/src/config-dir.ts
|
|
108535
108552
|
import { existsSync as existsSync61, realpathSync as realpathSync10 } from "node:fs";
|
|
108536
108553
|
import { homedir as homedir26 } from "node:os";
|
|
108537
|
-
import { join as
|
|
108554
|
+
import { join as join94, resolve as resolve27 } from "node:path";
|
|
108538
108555
|
function resolveConfigPath2(pathValue) {
|
|
108539
108556
|
const resolvedPath = resolve27(pathValue);
|
|
108540
108557
|
if (!existsSync61(resolvedPath))
|
|
@@ -108552,13 +108569,13 @@ function getOpenCodeCliConfigDir(env = process.env) {
|
|
|
108552
108569
|
if (customConfigDir) {
|
|
108553
108570
|
return resolveConfigPath2(customConfigDir);
|
|
108554
108571
|
}
|
|
108555
|
-
const xdgConfigDir = env["XDG_CONFIG_HOME"]?.trim() ||
|
|
108556
|
-
return resolveConfigPath2(
|
|
108572
|
+
const xdgConfigDir = env["XDG_CONFIG_HOME"]?.trim() || join94(homedir26(), ".config");
|
|
108573
|
+
return resolveConfigPath2(join94(xdgConfigDir, "opencode"));
|
|
108557
108574
|
}
|
|
108558
108575
|
|
|
108559
108576
|
// packages/mcp-client-core/src/mcp-oauth/storage-index.ts
|
|
108560
108577
|
import { chmodSync as chmodSync4, existsSync as existsSync62, readFileSync as readFileSync41, renameSync as renameSync7, writeFileSync as writeFileSync13 } from "node:fs";
|
|
108561
|
-
import { join as
|
|
108578
|
+
import { join as join95 } from "node:path";
|
|
108562
108579
|
var INDEX_FILE_NAME = "index.json";
|
|
108563
108580
|
function isTokenIndex(value) {
|
|
108564
108581
|
if (typeof value !== "object" || value === null || Array.isArray(value))
|
|
@@ -108566,7 +108583,7 @@ function isTokenIndex(value) {
|
|
|
108566
108583
|
return Object.values(value).every((entry) => typeof entry === "string");
|
|
108567
108584
|
}
|
|
108568
108585
|
function getIndexPath(storageDir) {
|
|
108569
|
-
return
|
|
108586
|
+
return join95(storageDir, INDEX_FILE_NAME);
|
|
108570
108587
|
}
|
|
108571
108588
|
function readTokenIndex(storageDir) {
|
|
108572
108589
|
const indexPath = getIndexPath(storageDir);
|
|
@@ -108610,16 +108627,16 @@ function deleteTokenIndexEntry(storageDir, hash) {
|
|
|
108610
108627
|
var STORAGE_DIR_NAME = "mcp-oauth";
|
|
108611
108628
|
var LEGACY_STORAGE_FILE_NAME = "mcp-oauth.json";
|
|
108612
108629
|
function getMcpOauthStorageDir() {
|
|
108613
|
-
return
|
|
108630
|
+
return join96(getOpenCodeCliConfigDir(), STORAGE_DIR_NAME);
|
|
108614
108631
|
}
|
|
108615
108632
|
function getMcpOauthServerHash(serverHost, resource) {
|
|
108616
108633
|
return createHash7("sha256").update(buildKey(serverHost, resource)).digest("hex").slice(0, 32);
|
|
108617
108634
|
}
|
|
108618
108635
|
function getMcpOauthStoragePath(serverHost, resource) {
|
|
108619
|
-
return
|
|
108636
|
+
return join96(getMcpOauthStorageDir(), `${getMcpOauthServerHash(serverHost, resource)}.json`);
|
|
108620
108637
|
}
|
|
108621
108638
|
function getLegacyStoragePath() {
|
|
108622
|
-
return
|
|
108639
|
+
return join96(getOpenCodeCliConfigDir(), LEGACY_STORAGE_FILE_NAME);
|
|
108623
108640
|
}
|
|
108624
108641
|
function normalizeHost2(serverHost) {
|
|
108625
108642
|
let host = serverHost.trim();
|
|
@@ -108713,7 +108730,7 @@ function readLegacyStore() {
|
|
|
108713
108730
|
}
|
|
108714
108731
|
function writeTokenFile(filePath, token) {
|
|
108715
108732
|
try {
|
|
108716
|
-
const dir =
|
|
108733
|
+
const dir = dirname37(filePath);
|
|
108717
108734
|
if (!existsSync63(dir)) {
|
|
108718
108735
|
mkdirSync17(dir, { recursive: true });
|
|
108719
108736
|
}
|
|
@@ -108798,7 +108815,7 @@ function listTokensByHost(serverHost) {
|
|
|
108798
108815
|
for (const [hash, indexedKey] of Object.entries(index)) {
|
|
108799
108816
|
if (!indexedKey.startsWith(prefix))
|
|
108800
108817
|
continue;
|
|
108801
|
-
const indexedToken = readTokenFile(
|
|
108818
|
+
const indexedToken = readTokenFile(join96(getMcpOauthStorageDir(), `${hash}.json`));
|
|
108802
108819
|
if (indexedToken)
|
|
108803
108820
|
result[indexedKey] = indexedToken;
|
|
108804
108821
|
}
|
|
@@ -108813,7 +108830,7 @@ function listAllTokens() {
|
|
|
108813
108830
|
for (const entry of readdirSync13(dir, { withFileTypes: true })) {
|
|
108814
108831
|
if (!entry.isFile() || !entry.name.endsWith(".json") || entry.name === "index.json")
|
|
108815
108832
|
continue;
|
|
108816
|
-
const token = readTokenFile(
|
|
108833
|
+
const token = readTokenFile(join96(dir, entry.name));
|
|
108817
108834
|
const hash = basename13(entry.name, ".json");
|
|
108818
108835
|
if (token)
|
|
108819
108836
|
result[index[hash] ?? hash] = token;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "lazycodex-ai",
|
|
3
|
-
"version": "5.1.
|
|
3
|
+
"version": "5.1.3",
|
|
4
4
|
"description": "The Best AI Agent Harness - Batteries-Included OpenCode Plugin with Multi-Model Orchestration, Parallel Background Agents, and Crafted LSP/AST Tools",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -122,10 +122,6 @@
|
|
|
122
122
|
"devDependencies": {},
|
|
123
123
|
"optionalDependencies": {},
|
|
124
124
|
"overrides": {
|
|
125
|
-
"@earendil-works/pi-agent-core": "0.84.2",
|
|
126
|
-
"@earendil-works/pi-ai": "0.84.2",
|
|
127
|
-
"@earendil-works/pi-coding-agent": "0.84.2",
|
|
128
|
-
"@earendil-works/pi-tui": "0.84.2",
|
|
129
125
|
"hono": "^4.13.8",
|
|
130
126
|
"@hono/node-server": "2.1.1",
|
|
131
127
|
"express-rate-limit": "^8.7.0",
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"command": "node \"${PLUGIN_ROOT}/components/bootstrap/dist/cli.js\" hook session-start",
|
|
9
9
|
"commandWindows": "powershell -NoProfile -ExecutionPolicy Bypass -File \"${PLUGIN_ROOT}\\components\\bootstrap\\scripts\\bootstrap.ps1\"",
|
|
10
10
|
"timeout": 30,
|
|
11
|
-
"statusMessage": "(OmO 5.1.
|
|
11
|
+
"statusMessage": "(OmO 5.1.3) Checking Bootstrap Provisioning"
|
|
12
12
|
}
|
|
13
13
|
]
|
|
14
14
|
}
|
|
@@ -146,6 +146,34 @@ function joinPatchLines(lines) {
|
|
|
146
146
|
`)}
|
|
147
147
|
`;
|
|
148
148
|
}
|
|
149
|
+
// ../../comment-checker-core/src/package-binary.ts
|
|
150
|
+
import { createRequire } from "node:module";
|
|
151
|
+
import { dirname, join } from "node:path";
|
|
152
|
+
var COMMENT_CHECKER_PACKAGE_NAME = "@code-yeongyu/comment-checker";
|
|
153
|
+
function isModuleResolutionMiss(error) {
|
|
154
|
+
return error instanceof Error || typeof error === "object" && error !== null && "name" in error && error.name === "ResolveMessage";
|
|
155
|
+
}
|
|
156
|
+
function findCommentCheckerPackageBinary(input) {
|
|
157
|
+
const packageName = input.packageName ?? COMMENT_CHECKER_PACKAGE_NAME;
|
|
158
|
+
const platformKey = `${input.platform ?? process.platform}-${input.arch ?? process.arch}`;
|
|
159
|
+
const packageDir = dirname(input.packageJsonPath);
|
|
160
|
+
const candidates = [
|
|
161
|
+
resolvePlatformPackageBinary(input.packageJsonPath, `${packageName}-${platformKey}`, input.binaryName),
|
|
162
|
+
join(packageDir, "vendor", platformKey, input.binaryName),
|
|
163
|
+
join(packageDir, "bin", input.binaryName)
|
|
164
|
+
];
|
|
165
|
+
return candidates.find((candidate) => candidate !== null && input.existsSync(candidate)) ?? null;
|
|
166
|
+
}
|
|
167
|
+
function resolvePlatformPackageBinary(packageJsonPath, platformPackageName, binaryName) {
|
|
168
|
+
try {
|
|
169
|
+
const manifestPath = createRequire(packageJsonPath).resolve(`${platformPackageName}/package.json`);
|
|
170
|
+
return join(dirname(manifestPath), "bin", binaryName);
|
|
171
|
+
} catch (error) {
|
|
172
|
+
if (isModuleResolutionMiss(error))
|
|
173
|
+
return null;
|
|
174
|
+
throw error;
|
|
175
|
+
}
|
|
176
|
+
}
|
|
149
177
|
// components/comment-checker/src/hook-input.ts
|
|
150
178
|
function toHookInput(request, context) {
|
|
151
179
|
return {
|
|
@@ -302,8 +330,7 @@ function getContentText(content) {
|
|
|
302
330
|
// components/comment-checker/src/runner.ts
|
|
303
331
|
import { spawn } from "node:child_process";
|
|
304
332
|
import { existsSync } from "node:fs";
|
|
305
|
-
import { createRequire } from "node:module";
|
|
306
|
-
import { dirname, join } from "node:path";
|
|
333
|
+
import { createRequire as createRequire2 } from "node:module";
|
|
307
334
|
var MAX_PROCESS_OUTPUT_BYTES = 64 * 1024;
|
|
308
335
|
async function runCommentChecker2(input, options = {}) {
|
|
309
336
|
const binaryPath = options.binaryPath ?? (options.resolveBinary ? options.resolveBinary() : resolveCommentCheckerBinary2());
|
|
@@ -361,7 +388,7 @@ function resolveCommentCheckerBinary2() {
|
|
|
361
388
|
}
|
|
362
389
|
function resolvePackageApiBinary() {
|
|
363
390
|
try {
|
|
364
|
-
const require2 =
|
|
391
|
+
const require2 = createRequire2(import.meta.url);
|
|
365
392
|
const packageExports = require2(commentCheckerPackageName());
|
|
366
393
|
if (!isCommentCheckerPackage(packageExports))
|
|
367
394
|
return;
|
|
@@ -373,10 +400,9 @@ function resolvePackageApiBinary() {
|
|
|
373
400
|
}
|
|
374
401
|
function resolvePackageBinary(binaryName) {
|
|
375
402
|
try {
|
|
376
|
-
const require2 =
|
|
377
|
-
const
|
|
378
|
-
|
|
379
|
-
return existsSync(binaryPath) ? binaryPath : undefined;
|
|
403
|
+
const require2 = createRequire2(import.meta.url);
|
|
404
|
+
const packageJsonPath = require2.resolve(`${commentCheckerPackageName()}/package.json`);
|
|
405
|
+
return findCommentCheckerPackageBinary({ packageJsonPath, binaryName, existsSync }) ?? undefined;
|
|
380
406
|
} catch {
|
|
381
407
|
return;
|
|
382
408
|
}
|