lazycodex-ai 5.0.0-beta.86 → 5.0.0-beta.88
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/cli/index.js +102 -79
- package/dist/cli-node/index.js +102 -79
- package/package.json +1 -1
- package/packages/omo-codex/plugin/.codex-plugin/plugin.json +1 -1
- package/packages/omo-codex/plugin/components/bootstrap/dist/cli.js +2 -0
- 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/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/comment-checker/package.json +1 -1
- 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/bundled-rules/hephaestus/gpt-6.md +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/README.md +1 -1
- package/packages/omo-codex/plugin/components/ultrawork/agents/plan.toml +2 -2
- package/packages/omo-codex/plugin/components/ultrawork/dist/cli.js +63 -89
- 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/ultrawork/src/directive-content.ts +1 -1
- package/packages/omo-codex/plugin/components/ulw-execute-continuation/directive.md +2 -2
- 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/directive.md +63 -89
- 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/components/ulw-loop/skills/ulw-loop/references/define-goal.md +2 -3
- package/packages/omo-codex/plugin/components/ulw-loop/skills/ulw-loop/references/full-workflow.md +2 -2
- 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/scripts/materialize-shared-upstreams.mjs +8 -2
- package/packages/omo-codex/plugin/scripts/sync-skills.mjs +2 -2
- package/packages/omo-codex/plugin/skills/browser/ATTRIBUTION.md +26 -14
- package/packages/omo-codex/plugin/skills/browser/SKILL.md +65 -52
- package/packages/omo-codex/plugin/skills/browser/references/commands.md +81 -66
- package/packages/omo-codex/plugin/skills/browser/references/install.md +31 -34
- package/packages/omo-codex/plugin/skills/browser/references/owned-engine/README.md +41 -21
- package/packages/omo-codex/plugin/skills/browser/references/owned-engine/frames-and-humans.md +33 -20
- package/packages/omo-codex/plugin/skills/browser/references/owned-engine/ladder.md +24 -22
- package/packages/omo-codex/plugin/skills/browser/references/owned-engine/network.md +35 -15
- package/packages/omo-codex/plugin/skills/browser/references/recipes/1password.md +13 -11
- package/packages/omo-codex/plugin/skills/browser/references/remote.md +5 -4
- package/packages/omo-codex/plugin/skills/browser/runtime/omowright/index.js +1534 -0
- package/packages/omo-codex/plugin/skills/browser/runtime/omowright/manifest.json +9 -0
- package/packages/omo-codex/plugin/skills/browser/runtime/omowright/page-bundle.js +1395 -0
- package/packages/omo-codex/plugin/skills/browser/scripts/browser-doctor.mjs +37 -32
- package/packages/omo-codex/plugin/skills/browser/scripts/browser-install.mjs +31 -44
- package/packages/omo-codex/plugin/skills/browser/scripts/omowright.mjs +25 -0
- package/packages/omo-codex/plugin/skills/debugging/SKILL.md +2 -2
- package/packages/omo-codex/plugin/skills/debugging/references/methodology/06-fix.md +3 -3
- package/packages/omo-codex/plugin/skills/debugging/references/methodology/08-qa.md +1 -1
- package/packages/omo-codex/plugin/skills/debugging/references/tools/browser-qa.md +104 -0
- package/packages/omo-codex/plugin/skills/frontend/SKILL.md +1 -1
- package/packages/omo-codex/plugin/skills/frontend/references/design/ambience-skill.md +2 -1
- package/packages/omo-codex/plugin/skills/frontend/references/design/clone-from-url.md +1 -1
- package/packages/omo-codex/plugin/skills/frontend/references/design/design-system-architecture.md +30 -7
- package/packages/omo-codex/plugin/skills/frontend/references/design/interaction-skill.md +17 -5
- package/packages/omo-codex/plugin/skills/programming/SKILL.md +12 -18
- package/packages/omo-codex/plugin/skills/programming/references/rust/README.md +43 -15
- package/packages/omo-codex/plugin/skills/programming/references/rust/api-design.md +81 -0
- package/packages/omo-codex/plugin/skills/programming/references/rust/async-tokio.md +60 -28
- package/packages/omo-codex/plugin/skills/programming/references/rust/axum-stack.md +1 -13
- package/packages/omo-codex/plugin/skills/programming/references/rust/cargo-strict.md +44 -8
- package/packages/omo-codex/plugin/skills/programming/references/rust/clap-stack.md +8 -3
- package/packages/omo-codex/plugin/skills/programming/references/rust/concurrency.md +66 -52
- package/packages/omo-codex/plugin/skills/programming/references/rust/libraries.md +35 -25
- package/packages/omo-codex/plugin/skills/programming/references/rust/macros.md +63 -0
- package/packages/omo-codex/plugin/skills/programming/references/rust/one-liners.md +5 -3
- package/packages/omo-codex/plugin/skills/programming/references/rust/proptest-insta.md +8 -0
- package/packages/omo-codex/plugin/skills/programming/references/rust/type-state.md +50 -12
- package/packages/omo-codex/plugin/skills/programming/references/rust/unsafe-discipline.md +34 -6
- package/packages/omo-codex/plugin/skills/programming/references/rust/zero-cost-safety.md +62 -52
- package/packages/omo-codex/plugin/skills/programming/references/rust-ub/miri-sanitizers-loom.md +1 -1
- package/packages/omo-codex/plugin/skills/programming/references/rust-ub/ub-taxonomy.md +6 -3
- package/packages/omo-codex/plugin/skills/programming/scripts/rust/check-no-excuse-rules.sh +86 -75
- package/packages/omo-codex/plugin/skills/programming/scripts/rust/new-project.py +31 -28
- package/packages/omo-codex/plugin/skills/review-work/SKILL.md +1 -1
- package/packages/omo-codex/plugin/skills/ultimate-browsing/SKILL.md +27 -20
- package/packages/omo-codex/plugin/skills/ultimate-browsing/engine/AGENTS.md +1 -1
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/chrome-stealth.md +32 -100
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/insane-search/README.md +5 -11
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/insane-search/playwright.md +20 -37
- package/packages/omo-codex/plugin/skills/ultrawork/SKILL.md +63 -89
- package/packages/omo-codex/plugin/skills/ulw-execute/SKILL.md +4 -4
- package/packages/omo-codex/plugin/skills/ulw-loop/references/define-goal.md +2 -3
- package/packages/omo-codex/plugin/skills/ulw-loop/references/full-workflow.md +2 -2
- package/packages/omo-codex/plugin/skills/visual-qa/SKILL.md +1 -1
- package/packages/omo-codex/plugin/skills/visual-qa/references/browser-setup.md +46 -46
- package/packages/omo-codex/plugin/test/sync-skills-test-support.mjs +2 -2
- package/packages/omo-codex/scripts/install-dist/install-local.mjs +4 -2
- package/packages/prompts-core/prompts/ultrawork/codex.md +63 -89
- package/packages/shared-skills/skills/browser/ATTRIBUTION.md +26 -14
- package/packages/shared-skills/skills/browser/SKILL.md +65 -52
- package/packages/shared-skills/skills/browser/references/commands.md +81 -66
- package/packages/shared-skills/skills/browser/references/install.md +31 -34
- package/packages/shared-skills/skills/browser/references/owned-engine/README.md +41 -21
- package/packages/shared-skills/skills/browser/references/owned-engine/frames-and-humans.md +33 -20
- package/packages/shared-skills/skills/browser/references/owned-engine/ladder.md +24 -22
- package/packages/shared-skills/skills/browser/references/owned-engine/network.md +35 -15
- package/packages/shared-skills/skills/browser/references/recipes/1password.md +13 -11
- package/packages/shared-skills/skills/browser/references/remote.md +5 -4
- package/packages/shared-skills/skills/browser/runtime/omowright/index.js +1534 -0
- package/packages/shared-skills/skills/browser/runtime/omowright/manifest.json +9 -0
- package/packages/shared-skills/skills/browser/runtime/omowright/page-bundle.js +1395 -0
- package/packages/shared-skills/skills/browser/scripts/browser-doctor.mjs +37 -32
- package/packages/shared-skills/skills/browser/scripts/browser-install.mjs +31 -44
- package/packages/shared-skills/skills/browser/scripts/omowright.mjs +25 -0
- package/packages/shared-skills/skills/debugging/SKILL.md +2 -2
- package/packages/shared-skills/skills/debugging/references/methodology/06-fix.md +3 -3
- package/packages/shared-skills/skills/debugging/references/methodology/08-qa.md +1 -1
- package/packages/shared-skills/skills/debugging/references/tools/browser-qa.md +104 -0
- package/packages/shared-skills/skills/frontend/SKILL.md +1 -1
- package/packages/shared-skills/skills/frontend/references/design/ambience-skill.md +2 -1
- package/packages/shared-skills/skills/frontend/references/design/clone-from-url.md +1 -1
- package/packages/shared-skills/skills/frontend/references/design/design-system-architecture.md +30 -7
- package/packages/shared-skills/skills/frontend/references/design/interaction-skill.md +17 -5
- package/packages/shared-skills/skills/programming/SKILL.md +12 -18
- package/packages/shared-skills/skills/programming/references/rust/README.md +43 -15
- package/packages/shared-skills/skills/programming/references/rust/api-design.md +81 -0
- package/packages/shared-skills/skills/programming/references/rust/async-tokio.md +60 -28
- package/packages/shared-skills/skills/programming/references/rust/axum-stack.md +1 -13
- package/packages/shared-skills/skills/programming/references/rust/cargo-strict.md +44 -8
- package/packages/shared-skills/skills/programming/references/rust/clap-stack.md +8 -3
- package/packages/shared-skills/skills/programming/references/rust/concurrency.md +66 -52
- package/packages/shared-skills/skills/programming/references/rust/libraries.md +35 -25
- package/packages/shared-skills/skills/programming/references/rust/macros.md +63 -0
- package/packages/shared-skills/skills/programming/references/rust/one-liners.md +5 -3
- package/packages/shared-skills/skills/programming/references/rust/proptest-insta.md +8 -0
- package/packages/shared-skills/skills/programming/references/rust/type-state.md +50 -12
- package/packages/shared-skills/skills/programming/references/rust/unsafe-discipline.md +34 -6
- package/packages/shared-skills/skills/programming/references/rust/zero-cost-safety.md +62 -52
- package/packages/shared-skills/skills/programming/references/rust-ub/miri-sanitizers-loom.md +1 -1
- package/packages/shared-skills/skills/programming/references/rust-ub/ub-taxonomy.md +6 -3
- package/packages/shared-skills/skills/programming/scripts/rust/check-no-excuse-rules.sh +86 -75
- package/packages/shared-skills/skills/programming/scripts/rust/check-no-excuse-rules.test.ts +83 -0
- package/packages/shared-skills/skills/programming/scripts/rust/new-project.py +31 -28
- package/packages/shared-skills/skills/review-work/SKILL.md +1 -1
- package/packages/shared-skills/skills/ultimate-browsing/SKILL.md +27 -20
- package/packages/shared-skills/skills/ultimate-browsing/engine/AGENTS.md +1 -1
- package/packages/shared-skills/skills/ultimate-browsing/references/chrome-stealth.md +32 -100
- package/packages/shared-skills/skills/ultimate-browsing/references/insane-search/README.md +5 -11
- package/packages/shared-skills/skills/ultimate-browsing/references/insane-search/playwright.md +20 -37
- package/packages/shared-skills/skills/ulw-execute/SKILL.md +4 -4
- package/packages/shared-skills/skills/visual-qa/SKILL.md +1 -1
- package/packages/shared-skills/skills/visual-qa/references/browser-setup.md +46 -46
- package/packages/omo-codex/plugin/skills/browser/scripts/browser-env.mjs +0 -41
- package/packages/omo-codex/plugin/skills/debugging/references/tools/playwright-cli.md +0 -112
- package/packages/omo-codex/plugin/skills/programming/scripts/rust/check-no-excuse-rules.py +0 -296
- package/packages/shared-skills/skills/browser/scripts/browser-env.mjs +0 -41
- package/packages/shared-skills/skills/debugging/references/tools/playwright-cli.md +0 -112
- package/packages/shared-skills/skills/programming/scripts/rust/check-no-excuse-rules.py +0 -296
package/dist/cli/index.js
CHANGED
|
@@ -64,7 +64,7 @@ var package_default;
|
|
|
64
64
|
var init_package = __esm(() => {
|
|
65
65
|
package_default = {
|
|
66
66
|
name: "oh-my-opencode",
|
|
67
|
-
version: "5.0.0-beta.
|
|
67
|
+
version: "5.0.0-beta.88",
|
|
68
68
|
description: "The Best AI Agent Harness - Batteries-Included OpenCode Plugin with Multi-Model Orchestration, Parallel Background Agents, and Crafted LSP/AST Tools",
|
|
69
69
|
main: "./dist/index.js",
|
|
70
70
|
types: "dist/index.d.ts",
|
|
@@ -247,7 +247,7 @@ var init_package = __esm(() => {
|
|
|
247
247
|
zod: "^4.6.5"
|
|
248
248
|
},
|
|
249
249
|
devDependencies: {
|
|
250
|
-
"@code-yeongyu/senpi": "2026.9.23-
|
|
250
|
+
"@code-yeongyu/senpi": "2026.9.23-5",
|
|
251
251
|
"@oh-my-opencode/agents-md-core": "workspace:*",
|
|
252
252
|
"@oh-my-opencode/ast-grep-mcp": "workspace:*",
|
|
253
253
|
"@oh-my-opencode/boulder-state": "workspace:*",
|
|
@@ -283,22 +283,23 @@ var init_package = __esm(() => {
|
|
|
283
283
|
"@xterm/xterm": "^6.0.0",
|
|
284
284
|
"bun-types": "1.4.2",
|
|
285
285
|
"node-pty": "^1.1.0",
|
|
286
|
+
omowright: "github:code-yeongyu/omowright#25781c8ac04f9aae358b06551520b792ac45c6ed",
|
|
286
287
|
"puppeteer-core": "^25.11.0",
|
|
287
288
|
typescript: "^7.0.2"
|
|
288
289
|
},
|
|
289
290
|
optionalDependencies: {
|
|
290
|
-
"oh-my-opencode-darwin-arm64": "5.0.0-beta.
|
|
291
|
-
"oh-my-opencode-darwin-x64": "5.0.0-beta.
|
|
292
|
-
"oh-my-opencode-darwin-x64-baseline": "5.0.0-beta.
|
|
293
|
-
"oh-my-opencode-linux-arm64": "5.0.0-beta.
|
|
294
|
-
"oh-my-opencode-linux-arm64-musl": "5.0.0-beta.
|
|
295
|
-
"oh-my-opencode-linux-x64": "5.0.0-beta.
|
|
296
|
-
"oh-my-opencode-linux-x64-baseline": "5.0.0-beta.
|
|
297
|
-
"oh-my-opencode-linux-x64-musl": "5.0.0-beta.
|
|
298
|
-
"oh-my-opencode-linux-x64-musl-baseline": "5.0.0-beta.
|
|
299
|
-
"oh-my-opencode-windows-arm64": "5.0.0-beta.
|
|
300
|
-
"oh-my-opencode-windows-x64": "5.0.0-beta.
|
|
301
|
-
"oh-my-opencode-windows-x64-baseline": "5.0.0-beta.
|
|
291
|
+
"oh-my-opencode-darwin-arm64": "5.0.0-beta.88",
|
|
292
|
+
"oh-my-opencode-darwin-x64": "5.0.0-beta.88",
|
|
293
|
+
"oh-my-opencode-darwin-x64-baseline": "5.0.0-beta.88",
|
|
294
|
+
"oh-my-opencode-linux-arm64": "5.0.0-beta.88",
|
|
295
|
+
"oh-my-opencode-linux-arm64-musl": "5.0.0-beta.88",
|
|
296
|
+
"oh-my-opencode-linux-x64": "5.0.0-beta.88",
|
|
297
|
+
"oh-my-opencode-linux-x64-baseline": "5.0.0-beta.88",
|
|
298
|
+
"oh-my-opencode-linux-x64-musl": "5.0.0-beta.88",
|
|
299
|
+
"oh-my-opencode-linux-x64-musl-baseline": "5.0.0-beta.88",
|
|
300
|
+
"oh-my-opencode-windows-arm64": "5.0.0-beta.88",
|
|
301
|
+
"oh-my-opencode-windows-x64": "5.0.0-beta.88",
|
|
302
|
+
"oh-my-opencode-windows-x64-baseline": "5.0.0-beta.88"
|
|
302
303
|
},
|
|
303
304
|
overrides: {
|
|
304
305
|
"@earendil-works/pi-agent-core": "0.84.2",
|
|
@@ -7419,7 +7420,7 @@ var init_category_model_requirements = __esm(() => {
|
|
|
7419
7420
|
},
|
|
7420
7421
|
quick: {
|
|
7421
7422
|
fallbackChain: [
|
|
7422
|
-
{ providers: ["chatgpt-subscription"], model: "gpt-6-luna-fast", variant: "low" },
|
|
7423
|
+
{ providers: ["openai", "chatgpt-subscription"], model: "gpt-6-luna-fast", variant: "low" },
|
|
7423
7424
|
{ providers: ["deepseek"], model: "deepseek-flash", variant: "off" },
|
|
7424
7425
|
{
|
|
7425
7426
|
providers: ["qwen-token-plan", "alibaba-token-plan", "bailian-coding-plan"],
|
|
@@ -7464,7 +7465,7 @@ var init_category_model_requirements = __esm(() => {
|
|
|
7464
7465
|
{
|
|
7465
7466
|
providers: ["anthropic", "anthropic-api", "github-copilot", "opencode"],
|
|
7466
7467
|
model: "claude-opus-5-5",
|
|
7467
|
-
variant: "
|
|
7468
|
+
variant: "medium"
|
|
7468
7469
|
},
|
|
7469
7470
|
{ providers: ["zai-coding-plan", "opencode-go"], model: "glm-5.3", variant: "max" },
|
|
7470
7471
|
{
|
|
@@ -7475,6 +7476,7 @@ var init_category_model_requirements = __esm(() => {
|
|
|
7475
7476
|
]
|
|
7476
7477
|
},
|
|
7477
7478
|
writing: {
|
|
7479
|
+
requiresAnyModel: true,
|
|
7478
7480
|
fallbackChain: [
|
|
7479
7481
|
{
|
|
7480
7482
|
providers: ["anthropic", "anthropic-api", "github-copilot", "opencode"],
|
|
@@ -9460,7 +9462,7 @@ var init_openai_categories = __esm(() => {
|
|
|
9460
9462
|
},
|
|
9461
9463
|
{
|
|
9462
9464
|
name: "unspecified-high",
|
|
9463
|
-
config: { model: "anthropic/claude-opus-5-5", variant: "
|
|
9465
|
+
config: { model: "anthropic/claude-opus-5-5", variant: "medium" },
|
|
9464
9466
|
description: "Tasks that don't fit other categories, high effort required",
|
|
9465
9467
|
callerGuidance: UNSPECIFIED_HIGH_CATEGORY_CALLER_GUIDANCE,
|
|
9466
9468
|
promptAppend: UNSPECIFIED_HIGH_CATEGORY_PROMPT_APPEND,
|
|
@@ -74482,6 +74484,8 @@ var init_model_profile = __esm(() => {
|
|
|
74482
74484
|
init_fallback_models();
|
|
74483
74485
|
OmoModelProfileInputSchema = object({
|
|
74484
74486
|
display_name: string2().optional(),
|
|
74487
|
+
family: _enum(["daily", "geeky"]).optional(),
|
|
74488
|
+
tier: _enum(["normal", "heavy"]).optional(),
|
|
74485
74489
|
models: array(union([string2(), OmoFallbackModelObjectSchema])).optional()
|
|
74486
74490
|
}).strict();
|
|
74487
74491
|
OmoModelProfileSchema = preprocess((value) => isRecord8(value) ? normalizeLegacyModelFields(value) : value, OmoModelProfileInputSchema);
|
|
@@ -77075,8 +77079,7 @@ var init_openai_only_model_catalog = __esm(() => {
|
|
|
77075
77079
|
OPENAI_ONLY_CATEGORY_OVERRIDES = {
|
|
77076
77080
|
artistry: { model: "openai/gpt-5.6-sol", variant: "xhigh" },
|
|
77077
77081
|
quick: { model: "openai/gpt-6-luna-fast" },
|
|
77078
|
-
"visual-engineering": { model: "openai/gpt-5.6-sol", variant: "high" }
|
|
77079
|
-
writing: { model: "openai/gpt-5.6-sol", variant: "medium" }
|
|
77082
|
+
"visual-engineering": { model: "openai/gpt-5.6-sol", variant: "high" }
|
|
77080
77083
|
};
|
|
77081
77084
|
});
|
|
77082
77085
|
|
|
@@ -77267,7 +77270,7 @@ function generateModelConfig(config) {
|
|
|
77267
77270
|
return {
|
|
77268
77271
|
$schema: SCHEMA_URL,
|
|
77269
77272
|
agents: Object.fromEntries(Object.entries(CLI_AGENT_MODEL_REQUIREMENTS).filter(([role, req]) => !(role === "sisyphus" && req.requiresAnyModel)).map(([role]) => [role, { model: ULTIMATE_FALLBACK }])),
|
|
77270
|
-
categories: Object.fromEntries(Object.
|
|
77273
|
+
categories: Object.fromEntries(Object.entries(CLI_CATEGORY_MODEL_REQUIREMENTS).filter(([, req]) => !req.requiresAnyModel).map(([cat]) => [cat, { model: ULTIMATE_FALLBACK }]))
|
|
77271
77274
|
};
|
|
77272
77275
|
}
|
|
77273
77276
|
const agents = {};
|
|
@@ -77335,6 +77338,9 @@ function generateModelConfig(config) {
|
|
|
77335
77338
|
}
|
|
77336
77339
|
for (const [cat, req] of Object.entries(CLI_CATEGORY_MODEL_REQUIREMENTS)) {
|
|
77337
77340
|
const fallbackChain = cat === "unspecified-high" && !avail.isMaxPlan ? CLI_CATEGORY_MODEL_REQUIREMENTS["unspecified-low"].fallbackChain : req.fallbackChain;
|
|
77341
|
+
if (req.requiresAnyModel && !isAnyFallbackEntryAvailable(fallbackChain, avail)) {
|
|
77342
|
+
continue;
|
|
77343
|
+
}
|
|
77338
77344
|
if (req.requiresModel && !isRequiredModelAvailable(req.requiresModel, req.fallbackChain, avail)) {
|
|
77339
77345
|
continue;
|
|
77340
77346
|
}
|
|
@@ -88753,7 +88759,7 @@ var package_default2;
|
|
|
88753
88759
|
var init_package2 = __esm(() => {
|
|
88754
88760
|
package_default2 = {
|
|
88755
88761
|
name: "@oh-my-opencode/omo-codex",
|
|
88756
|
-
version: "5.0.0-beta.
|
|
88762
|
+
version: "5.0.0-beta.88",
|
|
88757
88763
|
type: "module",
|
|
88758
88764
|
private: true,
|
|
88759
88765
|
description: "Codex harness adapter for oh-my-openagent. Vendored Codex plugin namespace (omo) + TypeScript installer + telemetry.",
|
|
@@ -105357,28 +105363,41 @@ init_src();
|
|
|
105357
105363
|
import { existsSync as existsSync53 } from "fs";
|
|
105358
105364
|
import { createRequire as createRequire2 } from "module";
|
|
105359
105365
|
import { homedir as homedir19 } from "os";
|
|
105360
|
-
import { dirname as dirname31, join as
|
|
105366
|
+
import { dirname as dirname31, join as join83 } from "path";
|
|
105361
105367
|
|
|
105368
|
+
// packages/omo-opencode/src/hooks/comment-checker/downloader.ts
|
|
105369
|
+
import { join as join82 } from "path";
|
|
105370
|
+
import { homedir as homedir18, tmpdir as tmpdir4 } from "os";
|
|
105371
|
+
// packages/comment-checker-core/src/release.ts
|
|
105372
|
+
import { join as join81 } from "path";
|
|
105373
|
+
function commentCheckerBinaryName(platform) {
|
|
105374
|
+
return platform === "win32" ? "comment-checker.exe" : "comment-checker";
|
|
105375
|
+
}
|
|
105376
|
+
function commentCheckerCacheDir(input) {
|
|
105377
|
+
if (input.platform === "win32") {
|
|
105378
|
+
const localAppData = input.env.LOCALAPPDATA || input.env.APPDATA;
|
|
105379
|
+
const base = localAppData || join81(input.homedir, "AppData", "Local");
|
|
105380
|
+
return join81(base, input.cacheDirName, "bin");
|
|
105381
|
+
}
|
|
105382
|
+
const base = input.env.XDG_CACHE_HOME || join81(input.homedir, ".cache");
|
|
105383
|
+
return join81(base, input.cacheDirName, "bin");
|
|
105384
|
+
}
|
|
105362
105385
|
// packages/omo-opencode/src/hooks/comment-checker/downloader.ts
|
|
105363
105386
|
init_binary_downloader();
|
|
105364
105387
|
init_logger2();
|
|
105365
105388
|
init_plugin_identity();
|
|
105366
|
-
import { join as join81 } from "path";
|
|
105367
|
-
import { homedir as homedir18, tmpdir as tmpdir4 } from "os";
|
|
105368
105389
|
var DEBUG = process.env.COMMENT_CHECKER_DEBUG === "1";
|
|
105369
|
-
var DEBUG_FILE =
|
|
105390
|
+
var DEBUG_FILE = join82(tmpdir4(), "comment-checker-debug.log");
|
|
105370
105391
|
function getCacheDir2() {
|
|
105371
|
-
|
|
105372
|
-
|
|
105373
|
-
|
|
105374
|
-
|
|
105375
|
-
|
|
105376
|
-
|
|
105377
|
-
const base = xdgCache || join81(homedir18(), ".cache");
|
|
105378
|
-
return join81(base, CACHE_DIR_NAME, "bin");
|
|
105392
|
+
return commentCheckerCacheDir({
|
|
105393
|
+
platform: process.platform,
|
|
105394
|
+
env: process.env,
|
|
105395
|
+
homedir: homedir18(),
|
|
105396
|
+
cacheDirName: CACHE_DIR_NAME
|
|
105397
|
+
});
|
|
105379
105398
|
}
|
|
105380
105399
|
function getBinaryName() {
|
|
105381
|
-
return process.platform
|
|
105400
|
+
return commentCheckerBinaryName(process.platform);
|
|
105382
105401
|
}
|
|
105383
105402
|
function getCachedBinaryPath2() {
|
|
105384
105403
|
return getCachedBinaryPath(getCacheDir2(), getBinaryName());
|
|
@@ -105425,7 +105444,7 @@ async function getBinaryVersion(binary) {
|
|
|
105425
105444
|
}
|
|
105426
105445
|
}
|
|
105427
105446
|
async function checkAstGrepCli() {
|
|
105428
|
-
const runtimeDir = astGrepRuntimeDir(
|
|
105447
|
+
const runtimeDir = astGrepRuntimeDir(join83(homedir19(), ".omo"));
|
|
105429
105448
|
const sgPath = findSgBinarySync({ runtimeDir });
|
|
105430
105449
|
if (sgPath === null) {
|
|
105431
105450
|
return {
|
|
@@ -105455,10 +105474,10 @@ function findCommentCheckerPackageBinary(baseDirOverride, resolvePackageJsonPath
|
|
|
105455
105474
|
const platformKey = `${process.platform}-${process.arch === "x64" ? "x64" : process.arch}`;
|
|
105456
105475
|
try {
|
|
105457
105476
|
const packageDir = baseDirOverride ?? dirname31(resolvePackageJsonPath());
|
|
105458
|
-
const vendorPath =
|
|
105477
|
+
const vendorPath = join83(packageDir, "vendor", platformKey, binaryName);
|
|
105459
105478
|
if (existsSync53(vendorPath))
|
|
105460
105479
|
return vendorPath;
|
|
105461
|
-
const binPath =
|
|
105480
|
+
const binPath = join83(packageDir, "bin", binaryName);
|
|
105462
105481
|
if (existsSync53(binPath))
|
|
105463
105482
|
return binPath;
|
|
105464
105483
|
} catch (error) {
|
|
@@ -105834,13 +105853,13 @@ function getInstalledLspServers(options = {}) {
|
|
|
105834
105853
|
init_shared();
|
|
105835
105854
|
import { existsSync as existsSync55, readFileSync as readFileSync35 } from "fs";
|
|
105836
105855
|
import { homedir as homedir20 } from "os";
|
|
105837
|
-
import { join as
|
|
105856
|
+
import { join as join84 } from "path";
|
|
105838
105857
|
var BUILTIN_MCP_SERVERS = ["websearch", "context7", "grep_app", "lsp"];
|
|
105839
105858
|
function getMcpConfigPaths() {
|
|
105840
105859
|
return [
|
|
105841
|
-
|
|
105842
|
-
|
|
105843
|
-
|
|
105860
|
+
join84(homedir20(), ".claude", ".mcp.json"),
|
|
105861
|
+
join84(process.cwd(), ".mcp.json"),
|
|
105862
|
+
join84(process.cwd(), ".claude", ".mcp.json")
|
|
105844
105863
|
];
|
|
105845
105864
|
}
|
|
105846
105865
|
function loadUserMcpConfig() {
|
|
@@ -106122,7 +106141,7 @@ init_src();
|
|
|
106122
106141
|
import { existsSync as existsSync57 } from "fs";
|
|
106123
106142
|
import { lstat as lstat16, readdir as readdir14, readFile as readFile28 } from "fs/promises";
|
|
106124
106143
|
import { homedir as homedir22 } from "os";
|
|
106125
|
-
import { basename as basename11, join as
|
|
106144
|
+
import { basename as basename11, join as join85, resolve as resolve23 } from "path";
|
|
106126
106145
|
// packages/omo-opencode/package.json
|
|
106127
106146
|
var package_default3 = {
|
|
106128
106147
|
name: "@oh-my-opencode/omo-opencode",
|
|
@@ -106134,6 +106153,10 @@ var package_default3 = {
|
|
|
106134
106153
|
"./config-migration": {
|
|
106135
106154
|
types: "./src/config-migration/index.ts",
|
|
106136
106155
|
import: "./src/config-migration/index.ts"
|
|
106156
|
+
},
|
|
106157
|
+
"./binary-downloader": {
|
|
106158
|
+
types: "./src/shared/binary-downloader.ts",
|
|
106159
|
+
import: "./src/shared/binary-downloader.ts"
|
|
106137
106160
|
}
|
|
106138
106161
|
},
|
|
106139
106162
|
scripts: {
|
|
@@ -106188,13 +106211,13 @@ var CODEX_BIN_NAMES = [
|
|
|
106188
106211
|
"omo-git-bash-hook"
|
|
106189
106212
|
];
|
|
106190
106213
|
async function gatherCodexSummary(deps = {}) {
|
|
106191
|
-
const codexHome = resolve23(deps.codexHome ?? process.env.CODEX_HOME ??
|
|
106214
|
+
const codexHome = resolve23(deps.codexHome ?? process.env.CODEX_HOME ?? join85(homedir22(), ".codex"));
|
|
106192
106215
|
const binDir = resolveCodexInstallerBinDir({ binDir: deps.binDir, codexHome, env: process.env });
|
|
106193
106216
|
const detection = await (deps.detectCodexInstallation ?? detectCodexInstallation)();
|
|
106194
106217
|
const pluginRoot = await resolveInstalledPluginRoot(codexHome);
|
|
106195
|
-
const manifest = pluginRoot === null ? null : await readJson(
|
|
106196
|
-
const installSnapshot = pluginRoot === null ? null : await readJson(
|
|
106197
|
-
const configPath =
|
|
106218
|
+
const manifest = pluginRoot === null ? null : await readJson(join85(pluginRoot, ".codex-plugin", "plugin.json"));
|
|
106219
|
+
const installSnapshot = pluginRoot === null ? null : await readJson(join85(pluginRoot, "lazycodex-install.json"));
|
|
106220
|
+
const configPath = join85(codexHome, "config.toml");
|
|
106198
106221
|
const pluginVersion = stringField(manifest, "version");
|
|
106199
106222
|
return {
|
|
106200
106223
|
codexPath: detection.found && "path" in detection ? detection.path : null,
|
|
@@ -106251,7 +106274,7 @@ function buildCodexIssues(summary) {
|
|
|
106251
106274
|
if (summary.pluginRoot === null) {
|
|
106252
106275
|
issues.push({
|
|
106253
106276
|
title: "OMO Codex plugin is not installed",
|
|
106254
|
-
description: `Expected cached plugin at ${
|
|
106277
|
+
description: `Expected cached plugin at ${join85("plugins", "cache", MARKETPLACE_NAME, PLUGIN_NAME2, DEFAULT_PLUGIN_VERSION)} under CODEX_HOME.`,
|
|
106255
106278
|
fix: "Run: npx lazycodex-ai install",
|
|
106256
106279
|
severity: "error",
|
|
106257
106280
|
affects: ["plugin loading"]
|
|
@@ -106316,12 +106339,12 @@ function buildCodexIssues(summary) {
|
|
|
106316
106339
|
return issues;
|
|
106317
106340
|
}
|
|
106318
106341
|
async function resolveInstalledPluginRoot(codexHome) {
|
|
106319
|
-
const pluginRoot =
|
|
106342
|
+
const pluginRoot = join85(codexHome, "plugins", "cache", MARKETPLACE_NAME, PLUGIN_NAME2);
|
|
106320
106343
|
if (!existsSync57(pluginRoot))
|
|
106321
106344
|
return null;
|
|
106322
106345
|
const versions = await readdir14(pluginRoot, { withFileTypes: true });
|
|
106323
106346
|
const candidates = versions.filter((entry) => entry.isDirectory()).map((entry) => entry.name).sort(compareVersionsDescending);
|
|
106324
|
-
return candidates.length === 0 ? null :
|
|
106347
|
+
return candidates.length === 0 ? null : join85(pluginRoot, candidates[0] ?? DEFAULT_PLUGIN_VERSION);
|
|
106325
106348
|
}
|
|
106326
106349
|
async function readCodexConfigSummary(configPath) {
|
|
106327
106350
|
if (!existsSync57(configPath)) {
|
|
@@ -106349,13 +106372,13 @@ async function readCodexConfigSummary(configPath) {
|
|
|
106349
106372
|
async function readLinkedBins(binDir) {
|
|
106350
106373
|
const linked = [];
|
|
106351
106374
|
for (const name of CODEX_BIN_NAMES) {
|
|
106352
|
-
if (await pathExists2(
|
|
106375
|
+
if (await pathExists2(join85(binDir, process.platform === "win32" ? `${name}.cmd` : name)))
|
|
106353
106376
|
linked.push(name);
|
|
106354
106377
|
}
|
|
106355
106378
|
return linked;
|
|
106356
106379
|
}
|
|
106357
106380
|
async function readLinkedAgents(codexHome) {
|
|
106358
|
-
const agentsDir =
|
|
106381
|
+
const agentsDir = join85(codexHome, "agents");
|
|
106359
106382
|
if (!existsSync57(agentsDir))
|
|
106360
106383
|
return [];
|
|
106361
106384
|
const entries = await readdir14(agentsDir, { withFileTypes: true });
|
|
@@ -106489,7 +106512,7 @@ function resolveLatestVersion(input) {
|
|
|
106489
106512
|
init_src();
|
|
106490
106513
|
import { readdir as readdir15, readFile as readFile29, stat as stat7 } from "fs/promises";
|
|
106491
106514
|
import { homedir as homedir23 } from "os";
|
|
106492
|
-
import { dirname as dirname33, isAbsolute as isAbsolute13, join as
|
|
106515
|
+
import { dirname as dirname33, isAbsolute as isAbsolute13, join as join86, relative as relative9, resolve as resolve24, sep as sep9 } from "path";
|
|
106493
106516
|
var CODEX_COMPONENTS_CHECK_ID = "codex-components";
|
|
106494
106517
|
var CODEX_COMPONENTS_CHECK_NAME = "codex-components";
|
|
106495
106518
|
var PLUGIN_DATA_DIR_NAME = "omo-sisyphuslabs";
|
|
@@ -106499,7 +106522,7 @@ async function checkCodexComponents(deps = {}) {
|
|
|
106499
106522
|
const env = deps.env ?? process.env;
|
|
106500
106523
|
const platform = deps.platform ?? process.platform;
|
|
106501
106524
|
const arch = deps.arch ?? process.arch;
|
|
106502
|
-
const codexHome = resolve24(deps.codexHome ?? env["CODEX_HOME"] ??
|
|
106525
|
+
const codexHome = resolve24(deps.codexHome ?? env["CODEX_HOME"] ?? join86(homedir23(), ".codex"));
|
|
106503
106526
|
const summary = await gatherCodexSummary({ ...deps, codexHome });
|
|
106504
106527
|
if (summary.pluginRoot === null) {
|
|
106505
106528
|
return {
|
|
@@ -106524,7 +106547,7 @@ async function checkCodexComponents(deps = {}) {
|
|
|
106524
106547
|
});
|
|
106525
106548
|
}
|
|
106526
106549
|
const runtimeSgDir = runtimeSgDirectory(codexHome, platform, arch);
|
|
106527
|
-
const runtimeSgPath =
|
|
106550
|
+
const runtimeSgPath = join86(runtimeSgDir, sgBinaryName(platform));
|
|
106528
106551
|
const sg = findSgBinarySync({
|
|
106529
106552
|
arch,
|
|
106530
106553
|
env,
|
|
@@ -106561,12 +106584,12 @@ async function auditBundleTargets(pluginRoot) {
|
|
|
106561
106584
|
let referencedCount = 0;
|
|
106562
106585
|
for (const manifestPath of await findManifestPaths(pluginRoot, ".mcp.json")) {
|
|
106563
106586
|
const manifest = await readJson2(manifestPath);
|
|
106564
|
-
if (manifest === null || !
|
|
106587
|
+
if (manifest === null || !isRecord18(manifest["mcpServers"]))
|
|
106565
106588
|
continue;
|
|
106566
106589
|
const manifestRoot = dirname33(manifestPath);
|
|
106567
106590
|
const isRootManifest = resolve24(manifestRoot) === resolve24(pluginRoot);
|
|
106568
106591
|
for (const server of Object.values(manifest["mcpServers"])) {
|
|
106569
|
-
if (!
|
|
106592
|
+
if (!isRecord18(server) || !Array.isArray(server["args"]))
|
|
106570
106593
|
continue;
|
|
106571
106594
|
for (const arg of server["args"]) {
|
|
106572
106595
|
if (typeof arg !== "string" || !isPluginRuntimePathArg(arg))
|
|
@@ -106636,7 +106659,7 @@ async function findManifestPaths(root, manifestName) {
|
|
|
106636
106659
|
for (const entry of entries) {
|
|
106637
106660
|
if (entry.name === "node_modules" || entry.name === ".git")
|
|
106638
106661
|
continue;
|
|
106639
|
-
const entryPath =
|
|
106662
|
+
const entryPath = join86(root, entry.name);
|
|
106640
106663
|
if (entry.isDirectory()) {
|
|
106641
106664
|
paths.push(...await findManifestPaths(entryPath, manifestName));
|
|
106642
106665
|
continue;
|
|
@@ -106652,7 +106675,7 @@ function collectHookCommands(value, commands) {
|
|
|
106652
106675
|
collectHookCommands(item, commands);
|
|
106653
106676
|
return;
|
|
106654
106677
|
}
|
|
106655
|
-
if (!
|
|
106678
|
+
if (!isRecord18(value))
|
|
106656
106679
|
return;
|
|
106657
106680
|
if (value["type"] === "command") {
|
|
106658
106681
|
if (typeof value["command"] === "string")
|
|
@@ -106680,18 +106703,18 @@ function isPluginRuntimePathArg(arg) {
|
|
|
106680
106703
|
return normalized.endsWith(".js") && normalized.includes("/dist/") && (normalized.startsWith("./") || normalized.startsWith("../") || normalized.startsWith("components/") || normalized.startsWith("/") || isAbsolute13(arg));
|
|
106681
106704
|
}
|
|
106682
106705
|
function runtimeSgDirectory(codexHome, platform, arch) {
|
|
106683
|
-
return
|
|
106706
|
+
return join86(codexHome, "runtime", "ast-grep", runtimeSlug(platform, arch));
|
|
106684
106707
|
}
|
|
106685
106708
|
function describeSgSource(sgPath, env, runtimeSgDir, platform) {
|
|
106686
106709
|
const override = env[SG_PATH_ENV_KEY]?.trim();
|
|
106687
106710
|
if (override !== undefined && override.length > 0 && sgPath === override)
|
|
106688
106711
|
return `env override ${SG_PATH_ENV_KEY}`;
|
|
106689
|
-
if (sgPath ===
|
|
106712
|
+
if (sgPath === join86(runtimeSgDir, sgBinaryName(platform)))
|
|
106690
106713
|
return "runtime dir";
|
|
106691
106714
|
return "PATH";
|
|
106692
106715
|
}
|
|
106693
106716
|
async function readBootstrapStateSummary(codexHome) {
|
|
106694
|
-
const statePath =
|
|
106717
|
+
const statePath = join86(codexHome, "plugins", "data", PLUGIN_DATA_DIR_NAME, "bootstrap", "state.json");
|
|
106695
106718
|
const raw = await readJson2(statePath);
|
|
106696
106719
|
if (raw === null)
|
|
106697
106720
|
return null;
|
|
@@ -106707,7 +106730,7 @@ function parseDegradedEntries(value) {
|
|
|
106707
106730
|
return [];
|
|
106708
106731
|
const entries = [];
|
|
106709
106732
|
for (const item of value) {
|
|
106710
|
-
if (!
|
|
106733
|
+
if (!isRecord18(item))
|
|
106711
106734
|
continue;
|
|
106712
106735
|
if (typeof item["component"] !== "string" || typeof item["reason"] !== "string")
|
|
106713
106736
|
continue;
|
|
@@ -106741,7 +106764,7 @@ function degradedDetailLines(entries) {
|
|
|
106741
106764
|
async function readJson2(path) {
|
|
106742
106765
|
try {
|
|
106743
106766
|
const parsed = JSON.parse(await readFile29(path, "utf8"));
|
|
106744
|
-
return
|
|
106767
|
+
return isRecord18(parsed) ? parsed : null;
|
|
106745
106768
|
} catch (error) {
|
|
106746
106769
|
if (error instanceof Error)
|
|
106747
106770
|
return null;
|
|
@@ -106762,7 +106785,7 @@ function normalizeRelative(root, target) {
|
|
|
106762
106785
|
function normalizePathSeparators(path) {
|
|
106763
106786
|
return path.split("\\").join("/");
|
|
106764
106787
|
}
|
|
106765
|
-
function
|
|
106788
|
+
function isRecord18(value) {
|
|
106766
106789
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
106767
106790
|
}
|
|
106768
106791
|
|
|
@@ -106770,16 +106793,16 @@ function isRecord17(value) {
|
|
|
106770
106793
|
import { existsSync as existsSync58 } from "fs";
|
|
106771
106794
|
import { readFile as readFile30 } from "fs/promises";
|
|
106772
106795
|
import { homedir as homedir24 } from "os";
|
|
106773
|
-
import { join as
|
|
106796
|
+
import { join as join87, resolve as resolve25 } from "path";
|
|
106774
106797
|
var RUNTIME_WRAPPER_MARKER2 = "OMO_GENERATED_RUNTIME_WRAPPER";
|
|
106775
106798
|
var CHECK_NAME = "codex-runtime-wrapper";
|
|
106776
106799
|
var REINSTALL_COMMAND = "npx --yes lazycodex-ai@latest install --no-tui";
|
|
106777
106800
|
async function checkCodexRuntimeWrapper(deps = {}) {
|
|
106778
|
-
const codexHome = resolve25(deps.codexHome ?? process.env.CODEX_HOME ??
|
|
106801
|
+
const codexHome = resolve25(deps.codexHome ?? process.env.CODEX_HOME ?? join87(homedir24(), ".codex"));
|
|
106779
106802
|
const binDir = resolveCodexInstallerBinDir({ binDir: deps.binDir, codexHome, env: process.env });
|
|
106780
106803
|
const platform = deps.platform ?? process.platform;
|
|
106781
|
-
const wrapperPath =
|
|
106782
|
-
const legacyWrapperPath =
|
|
106804
|
+
const wrapperPath = join87(binDir, platform === "win32" ? "omo-agent-toolkit.cmd" : "omo-agent-toolkit");
|
|
106805
|
+
const legacyWrapperPath = join87(binDir, platform === "win32" ? "omo.cmd" : "omo");
|
|
106783
106806
|
const [wrapper, legacyWrapper] = await Promise.all([readRuntimeWrapper(wrapperPath), readRuntimeWrapper(legacyWrapperPath)]);
|
|
106784
106807
|
const issues = [];
|
|
106785
106808
|
if (wrapper?.includes(RUNTIME_WRAPPER_MARKER2) === true) {
|
|
@@ -107315,12 +107338,12 @@ import {
|
|
|
107315
107338
|
unlinkSync as unlinkSync9,
|
|
107316
107339
|
writeFileSync as writeFileSync12
|
|
107317
107340
|
} from "fs";
|
|
107318
|
-
import { basename as basename12, dirname as dirname34, join as
|
|
107341
|
+
import { basename as basename12, dirname as dirname34, join as join90 } from "path";
|
|
107319
107342
|
|
|
107320
107343
|
// packages/mcp-client-core/src/config-dir.ts
|
|
107321
107344
|
import { existsSync as existsSync59, realpathSync as realpathSync8 } from "fs";
|
|
107322
107345
|
import { homedir as homedir25 } from "os";
|
|
107323
|
-
import { join as
|
|
107346
|
+
import { join as join88, resolve as resolve26 } from "path";
|
|
107324
107347
|
function resolveConfigPath2(pathValue) {
|
|
107325
107348
|
const resolvedPath = resolve26(pathValue);
|
|
107326
107349
|
if (!existsSync59(resolvedPath))
|
|
@@ -107338,13 +107361,13 @@ function getOpenCodeCliConfigDir(env = process.env) {
|
|
|
107338
107361
|
if (customConfigDir) {
|
|
107339
107362
|
return resolveConfigPath2(customConfigDir);
|
|
107340
107363
|
}
|
|
107341
|
-
const xdgConfigDir = env["XDG_CONFIG_HOME"]?.trim() ||
|
|
107342
|
-
return resolveConfigPath2(
|
|
107364
|
+
const xdgConfigDir = env["XDG_CONFIG_HOME"]?.trim() || join88(homedir25(), ".config");
|
|
107365
|
+
return resolveConfigPath2(join88(xdgConfigDir, "opencode"));
|
|
107343
107366
|
}
|
|
107344
107367
|
|
|
107345
107368
|
// packages/mcp-client-core/src/mcp-oauth/storage-index.ts
|
|
107346
107369
|
import { chmodSync as chmodSync4, existsSync as existsSync60, readFileSync as readFileSync37, renameSync as renameSync6, writeFileSync as writeFileSync11 } from "fs";
|
|
107347
|
-
import { join as
|
|
107370
|
+
import { join as join89 } from "path";
|
|
107348
107371
|
var INDEX_FILE_NAME = "index.json";
|
|
107349
107372
|
function isTokenIndex(value) {
|
|
107350
107373
|
if (typeof value !== "object" || value === null || Array.isArray(value))
|
|
@@ -107352,7 +107375,7 @@ function isTokenIndex(value) {
|
|
|
107352
107375
|
return Object.values(value).every((entry) => typeof entry === "string");
|
|
107353
107376
|
}
|
|
107354
107377
|
function getIndexPath(storageDir) {
|
|
107355
|
-
return
|
|
107378
|
+
return join89(storageDir, INDEX_FILE_NAME);
|
|
107356
107379
|
}
|
|
107357
107380
|
function readTokenIndex(storageDir) {
|
|
107358
107381
|
const indexPath = getIndexPath(storageDir);
|
|
@@ -107396,16 +107419,16 @@ function deleteTokenIndexEntry(storageDir, hash) {
|
|
|
107396
107419
|
var STORAGE_DIR_NAME = "mcp-oauth";
|
|
107397
107420
|
var LEGACY_STORAGE_FILE_NAME = "mcp-oauth.json";
|
|
107398
107421
|
function getMcpOauthStorageDir() {
|
|
107399
|
-
return
|
|
107422
|
+
return join90(getOpenCodeCliConfigDir(), STORAGE_DIR_NAME);
|
|
107400
107423
|
}
|
|
107401
107424
|
function getMcpOauthServerHash(serverHost, resource) {
|
|
107402
107425
|
return createHash7("sha256").update(buildKey(serverHost, resource)).digest("hex").slice(0, 32);
|
|
107403
107426
|
}
|
|
107404
107427
|
function getMcpOauthStoragePath(serverHost, resource) {
|
|
107405
|
-
return
|
|
107428
|
+
return join90(getMcpOauthStorageDir(), `${getMcpOauthServerHash(serverHost, resource)}.json`);
|
|
107406
107429
|
}
|
|
107407
107430
|
function getLegacyStoragePath() {
|
|
107408
|
-
return
|
|
107431
|
+
return join90(getOpenCodeCliConfigDir(), LEGACY_STORAGE_FILE_NAME);
|
|
107409
107432
|
}
|
|
107410
107433
|
function normalizeHost2(serverHost) {
|
|
107411
107434
|
let host = serverHost.trim();
|
|
@@ -107584,7 +107607,7 @@ function listTokensByHost(serverHost) {
|
|
|
107584
107607
|
for (const [hash, indexedKey] of Object.entries(index)) {
|
|
107585
107608
|
if (!indexedKey.startsWith(prefix))
|
|
107586
107609
|
continue;
|
|
107587
|
-
const indexedToken = readTokenFile(
|
|
107610
|
+
const indexedToken = readTokenFile(join90(getMcpOauthStorageDir(), `${hash}.json`));
|
|
107588
107611
|
if (indexedToken)
|
|
107589
107612
|
result[indexedKey] = indexedToken;
|
|
107590
107613
|
}
|
|
@@ -107599,7 +107622,7 @@ function listAllTokens() {
|
|
|
107599
107622
|
for (const entry of readdirSync12(dir, { withFileTypes: true })) {
|
|
107600
107623
|
if (!entry.isFile() || !entry.name.endsWith(".json") || entry.name === "index.json")
|
|
107601
107624
|
continue;
|
|
107602
|
-
const token = readTokenFile(
|
|
107625
|
+
const token = readTokenFile(join90(dir, entry.name));
|
|
107603
107626
|
const hash = basename12(entry.name, ".json");
|
|
107604
107627
|
if (token)
|
|
107605
107628
|
result[index[hash] ?? hash] = token;
|