lazycodex-ai 5.0.1 → 5.1.0

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.
Files changed (79) hide show
  1. package/README.ja.md +2 -1
  2. package/README.ko.md +2 -1
  3. package/README.md +2 -1
  4. package/README.ru.md +2 -1
  5. package/README.zh-cn.md +2 -1
  6. package/dist/cli/index.js +241 -144
  7. package/dist/cli-node/index.js +241 -144
  8. package/package.json +6 -1
  9. package/packages/omo-codex/plugin/.codex-plugin/plugin.json +1 -1
  10. package/packages/omo-codex/plugin/components/bootstrap/dist/cli.js +26 -3
  11. package/packages/omo-codex/plugin/components/bootstrap/hooks/hooks.json +1 -1
  12. package/packages/omo-codex/plugin/components/bootstrap/package.json +1 -1
  13. package/packages/omo-codex/plugin/components/comment-checker/hooks/hooks.json +1 -1
  14. package/packages/omo-codex/plugin/components/comment-checker/package.json +1 -1
  15. package/packages/omo-codex/plugin/components/git-bash/hooks/hooks.json +2 -2
  16. package/packages/omo-codex/plugin/components/git-bash/package.json +1 -1
  17. package/packages/omo-codex/plugin/components/lazycodex-executor-verify/hooks/hooks.json +1 -1
  18. package/packages/omo-codex/plugin/components/lazycodex-executor-verify/package.json +1 -1
  19. package/packages/omo-codex/plugin/components/lsp/dist/.omo-runtime-manifest.json +2 -2
  20. package/packages/omo-codex/plugin/components/lsp/hooks/hooks.json +2 -2
  21. package/packages/omo-codex/plugin/components/lsp/package.json +1 -1
  22. package/packages/omo-codex/plugin/components/rules/hooks/hooks.json +4 -4
  23. package/packages/omo-codex/plugin/components/rules/package.json +1 -1
  24. package/packages/omo-codex/plugin/components/teammode/hooks/hooks.json +1 -1
  25. package/packages/omo-codex/plugin/components/teammode/package.json +1 -1
  26. package/packages/omo-codex/plugin/components/telemetry/hooks/hooks.json +1 -1
  27. package/packages/omo-codex/plugin/components/telemetry/package.json +1 -1
  28. package/packages/omo-codex/plugin/components/ultrawork/hooks/hooks.json +1 -1
  29. package/packages/omo-codex/plugin/components/ultrawork/package.json +1 -1
  30. package/packages/omo-codex/plugin/components/ulw-execute-continuation/AGENTS.md +1 -1
  31. package/packages/omo-codex/plugin/components/ulw-execute-continuation/dist/cli.js +42 -32
  32. package/packages/omo-codex/plugin/components/ulw-execute-continuation/hooks/hooks.json +1 -1
  33. package/packages/omo-codex/plugin/components/ulw-execute-continuation/package.json +1 -1
  34. package/packages/omo-codex/plugin/components/ulw-execute-continuation/src/plan-checklist.ts +55 -29
  35. package/packages/omo-codex/plugin/components/ulw-execute-continuation/test/boulder-reader.test.ts +51 -0
  36. package/packages/omo-codex/plugin/components/ulw-loop/hooks/hooks.json +5 -5
  37. package/packages/omo-codex/plugin/components/ulw-loop/package.json +1 -1
  38. package/packages/omo-codex/plugin/hooks/post-compact-resetting-git-bash-mcp-reminder.json +1 -1
  39. package/packages/omo-codex/plugin/hooks/post-compact-resetting-lsp-diagnostics-cache.json +1 -1
  40. package/packages/omo-codex/plugin/hooks/post-compact-resetting-project-rule-cache.json +1 -1
  41. package/packages/omo-codex/plugin/hooks/post-tool-use-checking-comments.json +1 -1
  42. package/packages/omo-codex/plugin/hooks/post-tool-use-checking-lsp-diagnostics.json +1 -1
  43. package/packages/omo-codex/plugin/hooks/post-tool-use-checking-thread-title-hygiene.json +1 -1
  44. package/packages/omo-codex/plugin/hooks/post-tool-use-matching-project-rules.json +1 -1
  45. package/packages/omo-codex/plugin/hooks/post-tool-use-recording-spawn-admission.json +1 -1
  46. package/packages/omo-codex/plugin/hooks/pre-tool-use-enforcing-unlimited-goal-budget.json +1 -1
  47. package/packages/omo-codex/plugin/hooks/pre-tool-use-guarding-ulw-loop-spawns.json +1 -1
  48. package/packages/omo-codex/plugin/hooks/pre-tool-use-recommending-git-bash-mcp.json +1 -1
  49. package/packages/omo-codex/plugin/hooks/session-start-checking-auto-update.json +1 -1
  50. package/packages/omo-codex/plugin/hooks/session-start-checking-bootstrap-provisioning.json +1 -1
  51. package/packages/omo-codex/plugin/hooks/session-start-loading-project-rules.json +1 -1
  52. package/packages/omo-codex/plugin/hooks/session-start-recording-session-telemetry.json +1 -1
  53. package/packages/omo-codex/plugin/hooks/stop-checking-ulw-execute-continuation.json +1 -1
  54. package/packages/omo-codex/plugin/hooks/stop-checking-ulw-loop-resume.json +1 -1
  55. package/packages/omo-codex/plugin/hooks/subagent-stop-verifying-lazycodex-executor-evidence.json +1 -1
  56. package/packages/omo-codex/plugin/hooks/user-prompt-submit-checking-ultrawork-trigger.json +1 -1
  57. package/packages/omo-codex/plugin/hooks/user-prompt-submit-checking-ulw-loop-steering.json +1 -1
  58. package/packages/omo-codex/plugin/hooks/user-prompt-submit-loading-project-rules.json +1 -1
  59. package/packages/omo-codex/plugin/package-lock.json +12 -12
  60. package/packages/omo-codex/plugin/package.json +1 -1
  61. package/packages/omo-codex/plugin/skills/browser/runtime/omowright/manifest.json +1 -1
  62. package/packages/omo-codex/plugin/skills/coding-agent-sessions/SKILL.md +1 -1
  63. package/packages/omo-codex/plugin/skills/coding-agent-sessions/scripts/agent_sessions/aside_scanner.py +3 -0
  64. package/packages/omo-codex/plugin/skills/coding-agent-sessions/scripts/agent_sessions/cli.py +4 -0
  65. package/packages/omo-codex/plugin/skills/coding-agent-sessions/scripts/agent_sessions/file_scanners.py +6 -2
  66. package/packages/omo-codex/plugin/skills/coding-agent-sessions/scripts/agent_sessions/scanners.py +7 -1
  67. package/packages/omo-codex/plugin/skills/coding-agent-sessions/scripts/agent_sessions/transcript.py +3 -1
  68. package/packages/omo-codex/plugin/skills/coding-agent-sessions/scripts/agent_sessions/types.py +3 -1
  69. package/packages/omo-codex/plugin/skills/coding-agent-sessions/scripts/find-agent-sessions.py +4 -0
  70. package/packages/omo-codex/scripts/install-dist/install-local.mjs +37 -14
  71. package/packages/shared-skills/skills/browser/runtime/omowright/manifest.json +1 -1
  72. package/packages/shared-skills/skills/coding-agent-sessions/SKILL.md +1 -1
  73. package/packages/shared-skills/skills/coding-agent-sessions/scripts/agent_sessions/aside_scanner.py +3 -0
  74. package/packages/shared-skills/skills/coding-agent-sessions/scripts/agent_sessions/cli.py +4 -0
  75. package/packages/shared-skills/skills/coding-agent-sessions/scripts/agent_sessions/file_scanners.py +6 -2
  76. package/packages/shared-skills/skills/coding-agent-sessions/scripts/agent_sessions/scanners.py +7 -1
  77. package/packages/shared-skills/skills/coding-agent-sessions/scripts/agent_sessions/transcript.py +3 -1
  78. package/packages/shared-skills/skills/coding-agent-sessions/scripts/agent_sessions/types.py +3 -1
  79. package/packages/shared-skills/skills/coding-agent-sessions/scripts/find-agent-sessions.py +4 -0
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.1",
67
+ version: "5.1.0",
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",
@@ -97,6 +97,11 @@ var init_package = __esm(() => {
97
97
  "packages/omo-codex",
98
98
  "packages/omo-senpi",
99
99
  "packages/senpi-task",
100
+ "packages/senpi-desktop-protocol",
101
+ "packages/senpi-desktop-engine",
102
+ "packages/senpi-desktop-prelude",
103
+ "packages/senpi-desktop-service",
104
+ "packages/senpi-desktop-tool",
100
105
  "packages/omo-opencode",
101
106
  "packages/omo-native"
102
107
  ],
@@ -198,7 +203,7 @@ var init_package = __esm(() => {
198
203
  prepublishOnly: "bun run clean && bun run build:lsp-tools-mcp && bun run build:lsp-daemon && bun run build",
199
204
  "test:model-capabilities": "bun test --timeout 20000 packages/model-core/src/model-capability-aliases.test.ts packages/model-core/src/model-capability-guardrails.test.ts packages/model-core/src/model-capabilities.test.ts packages/omo-opencode/src/cli/doctor/checks/model-resolution.test.ts --bail",
200
205
  typecheck: "tsgo --noEmit && bun run typecheck:script && bun run typecheck:packages",
201
- "typecheck:packages": "tsgo --noEmit -p packages/rules-engine/tsconfig.json && tsgo --noEmit -p packages/delegate-core/tsconfig.json && tsgo --noEmit -p packages/mcp-stdio-core/tsconfig.json && tsgo --noEmit -p packages/mcp-client-core/tsconfig.json && tsgo --noEmit -p packages/git-bash-mcp/tsconfig.json && tsgo --noEmit -p packages/ast-grep-mcp/tsconfig.json && tsgo --noEmit -p packages/lsp-core/tsconfig.json && tsgo --noEmit -p packages/utils/tsconfig.json && tsgo --noEmit -p packages/model-core/tsconfig.json && tsgo --noEmit -p packages/omo-config-core/tsconfig.json && tsgo --noEmit -p packages/prompts-core/tsconfig.json && tsgo --noEmit -p packages/comment-checker-core/tsconfig.json && tsgo --noEmit -p packages/hashline-core/tsconfig.json && tsgo --noEmit -p packages/tmux-core/tsconfig.json && tsgo --noEmit -p packages/team-core/tsconfig.json && tsgo --noEmit -p packages/openclaw-core/tsconfig.json && tsgo --noEmit -p packages/boulder-state/tsconfig.json && tsgo --noEmit -p packages/isolation-core/tsconfig.json && tsgo --noEmit -p packages/memory-core/tsconfig.json && tsgo --noEmit -p packages/telemetry-core/tsconfig.json && tsgo --noEmit -p packages/claude-code-compat-core/tsconfig.json && tsgo --noEmit -p packages/skills-loader-core/tsconfig.json && tsgo --noEmit -p packages/agents-md-core/tsconfig.json && tsgo --noEmit -p packages/omo-codex/plugin/shared/tsconfig.json && tsgo --noEmit -p packages/omo-codex/tsconfig.json && tsgo --noEmit -p packages/omo-senpi/tsconfig.json && tsgo --noEmit -p packages/senpi-task/tsconfig.json && tsgo --noEmit -p packages/omo-opencode/tsconfig.json && tsgo --noEmit -p packages/omo-native/tsconfig.json",
206
+ "typecheck:packages": "tsgo --noEmit -p packages/rules-engine/tsconfig.json && tsgo --noEmit -p packages/delegate-core/tsconfig.json && tsgo --noEmit -p packages/mcp-stdio-core/tsconfig.json && tsgo --noEmit -p packages/mcp-client-core/tsconfig.json && tsgo --noEmit -p packages/git-bash-mcp/tsconfig.json && tsgo --noEmit -p packages/ast-grep-mcp/tsconfig.json && tsgo --noEmit -p packages/lsp-core/tsconfig.json && tsgo --noEmit -p packages/utils/tsconfig.json && tsgo --noEmit -p packages/model-core/tsconfig.json && tsgo --noEmit -p packages/omo-config-core/tsconfig.json && tsgo --noEmit -p packages/prompts-core/tsconfig.json && tsgo --noEmit -p packages/comment-checker-core/tsconfig.json && tsgo --noEmit -p packages/hashline-core/tsconfig.json && tsgo --noEmit -p packages/tmux-core/tsconfig.json && tsgo --noEmit -p packages/team-core/tsconfig.json && tsgo --noEmit -p packages/openclaw-core/tsconfig.json && tsgo --noEmit -p packages/boulder-state/tsconfig.json && tsgo --noEmit -p packages/isolation-core/tsconfig.json && tsgo --noEmit -p packages/memory-core/tsconfig.json && tsgo --noEmit -p packages/telemetry-core/tsconfig.json && tsgo --noEmit -p packages/claude-code-compat-core/tsconfig.json && tsgo --noEmit -p packages/skills-loader-core/tsconfig.json && tsgo --noEmit -p packages/agents-md-core/tsconfig.json && tsgo --noEmit -p packages/omo-codex/plugin/shared/tsconfig.json && tsgo --noEmit -p packages/omo-codex/tsconfig.json && tsgo --noEmit -p packages/omo-senpi/tsconfig.json && tsgo --noEmit -p packages/senpi-task/tsconfig.json && tsgo --noEmit -p packages/omo-opencode/tsconfig.json && tsgo --noEmit -p packages/omo-native/tsconfig.json && tsgo --noEmit -p packages/senpi-desktop-protocol/tsconfig.json && tsgo --noEmit -p packages/senpi-desktop-engine/tsconfig.json && tsgo --noEmit -p packages/senpi-desktop-prelude/tsconfig.json && tsgo --noEmit -p packages/senpi-desktop-service/tsconfig.json && tsgo --noEmit -p packages/senpi-desktop-tool/tsconfig.json",
202
207
  "typecheck:script": "tsgo --noEmit -p script/tsconfig.json",
203
208
  test: "bun test --timeout 20000",
204
209
  "changelog:section": "bun script/changelog-section.ts",
@@ -207,7 +212,8 @@ var init_package = __esm(() => {
207
212
  "test:senpi": "bun run build:senpi-plugin && tsgo --noEmit -p packages/omo-senpi/tsconfig.json && bun test --timeout 20000 packages/omo-senpi && bun test ./.agents/skills/senpi-qa/scripts/resolve-evidence-dir.test.mjs",
208
213
  "test:windows-codex": "bun run test:codex",
209
214
  "build:git-bash-mcp": "bun run --cwd packages/git-bash-mcp build",
210
- "build:ast-grep-mcp": "bun run --cwd packages/ast-grep-mcp build"
215
+ "build:ast-grep-mcp": "bun run --cwd packages/ast-grep-mcp build",
216
+ "test:desktop": "bun script/check-cargo-pinned-deps.mjs && bun run --cwd packages/senpi-desktop-protocol test && bun run --cwd packages/senpi-desktop-engine test && bun run --cwd packages/senpi-desktop-prelude test && bun run --cwd packages/senpi-desktop-service test && bun run --cwd packages/senpi-desktop-tool test"
211
217
  },
212
218
  keywords: [
213
219
  "opencode",
@@ -247,7 +253,7 @@ var init_package = __esm(() => {
247
253
  zod: "^4.6.5"
248
254
  },
249
255
  devDependencies: {
250
- "@code-yeongyu/senpi": "2026.9.27",
256
+ "@code-yeongyu/senpi": "2026.9.28-7",
251
257
  "@oh-my-opencode/agents-md-core": "workspace:*",
252
258
  "@oh-my-opencode/ast-grep-mcp": "workspace:*",
253
259
  "@oh-my-opencode/boulder-state": "workspace:*",
@@ -256,11 +262,11 @@ var init_package = __esm(() => {
256
262
  "@oh-my-opencode/delegate-core": "workspace:*",
257
263
  "@oh-my-opencode/git-bash-mcp": "workspace:*",
258
264
  "@oh-my-opencode/hashline-core": "workspace:*",
259
- "@oh-my-opencode/lsp-core": "workspace:*",
260
265
  "@oh-my-opencode/isolation-core": "workspace:*",
261
- "@oh-my-opencode/memory-core": "workspace:*",
266
+ "@oh-my-opencode/lsp-core": "workspace:*",
262
267
  "@oh-my-opencode/mcp-client-core": "workspace:*",
263
268
  "@oh-my-opencode/mcp-stdio-core": "workspace:*",
269
+ "@oh-my-opencode/memory-core": "workspace:*",
264
270
  "@oh-my-opencode/model-core": "workspace:*",
265
271
  "@oh-my-opencode/omo-codex": "workspace:*",
266
272
  "@oh-my-opencode/omo-config-core": "workspace:*",
@@ -269,6 +275,11 @@ var init_package = __esm(() => {
269
275
  "@oh-my-opencode/openclaw-core": "workspace:*",
270
276
  "@oh-my-opencode/prompts-core": "workspace:*",
271
277
  "@oh-my-opencode/rules-engine": "workspace:*",
278
+ "@oh-my-opencode/senpi-desktop-engine": "workspace:*",
279
+ "@oh-my-opencode/senpi-desktop-prelude": "workspace:*",
280
+ "@oh-my-opencode/senpi-desktop-protocol": "workspace:*",
281
+ "@oh-my-opencode/senpi-desktop-service": "workspace:*",
282
+ "@oh-my-opencode/senpi-desktop-tool": "workspace:*",
272
283
  "@oh-my-opencode/senpi-task": "workspace:*",
273
284
  "@oh-my-opencode/shared-skills": "workspace:*",
274
285
  "@oh-my-opencode/skills-loader-core": "workspace:*",
@@ -288,18 +299,18 @@ var init_package = __esm(() => {
288
299
  typescript: "^7.0.2"
289
300
  },
290
301
  optionalDependencies: {
291
- "oh-my-opencode-darwin-arm64": "5.0.1",
292
- "oh-my-opencode-darwin-x64": "5.0.1",
293
- "oh-my-opencode-darwin-x64-baseline": "5.0.1",
294
- "oh-my-opencode-linux-arm64": "5.0.1",
295
- "oh-my-opencode-linux-arm64-musl": "5.0.1",
296
- "oh-my-opencode-linux-x64": "5.0.1",
297
- "oh-my-opencode-linux-x64-baseline": "5.0.1",
298
- "oh-my-opencode-linux-x64-musl": "5.0.1",
299
- "oh-my-opencode-linux-x64-musl-baseline": "5.0.1",
300
- "oh-my-opencode-windows-arm64": "5.0.1",
301
- "oh-my-opencode-windows-x64": "5.0.1",
302
- "oh-my-opencode-windows-x64-baseline": "5.0.1"
302
+ "oh-my-opencode-darwin-arm64": "5.1.0",
303
+ "oh-my-opencode-darwin-x64": "5.1.0",
304
+ "oh-my-opencode-darwin-x64-baseline": "5.1.0",
305
+ "oh-my-opencode-linux-arm64": "5.1.0",
306
+ "oh-my-opencode-linux-arm64-musl": "5.1.0",
307
+ "oh-my-opencode-linux-x64": "5.1.0",
308
+ "oh-my-opencode-linux-x64-baseline": "5.1.0",
309
+ "oh-my-opencode-linux-x64-musl": "5.1.0",
310
+ "oh-my-opencode-linux-x64-musl-baseline": "5.1.0",
311
+ "oh-my-opencode-windows-arm64": "5.1.0",
312
+ "oh-my-opencode-windows-x64": "5.1.0",
313
+ "oh-my-opencode-windows-x64-baseline": "5.1.0"
303
314
  },
304
315
  overrides: {
305
316
  "@earendil-works/pi-agent-core": "0.84.2",
@@ -6396,6 +6407,9 @@ function getActiveReservation(sessionID) {
6396
6407
  pruneExpiredReservations();
6397
6408
  return promptAsyncReservations.get(sessionID);
6398
6409
  }
6410
+ function reservedDispatchResult(reservation) {
6411
+ return reservation.expiresAt === undefined ? { status: "reserved", reservedBy: reservation.source } : { status: "reserved", reservedBy: reservation.source, expiresAt: reservation.expiresAt };
6412
+ }
6399
6413
  function setPromptReservation(sessionID, reservation) {
6400
6414
  promptAsyncReservations.set(sessionID, reservation);
6401
6415
  }
@@ -6445,7 +6459,7 @@ async function dispatchAfterSessionIdle(args) {
6445
6459
  reservedBy: existing.source,
6446
6460
  reservedAgeMs: Date.now() - existing.reservedAt
6447
6461
  });
6448
- return { status: "reserved", reservedBy: existing.source };
6462
+ return reservedDispatchResult(existing);
6449
6463
  }
6450
6464
  const reservation = {
6451
6465
  source,
@@ -6983,7 +6997,7 @@ async function dispatchInternalPrompt(args) {
6983
6997
  if (queueBehavior === "defer") {
6984
6998
  const activeReservation = getActiveReservation(sessionID);
6985
6999
  if (activeReservation) {
6986
- return { status: "reserved", reservedBy: activeReservation.source };
7000
+ return reservedDispatchResult(activeReservation);
6987
7001
  }
6988
7002
  const queuedBy = getQueuedPromptBlocker(sessionID);
6989
7003
  if (queuedBy !== undefined || isPromptQueueDraining(sessionID)) {
@@ -8040,8 +8054,17 @@ var init_model_resolver = () => {};
8040
8054
  // packages/model-core/src/fallback-chain-from-models.ts
8041
8055
  var init_fallback_chain_from_models = () => {};
8042
8056
 
8057
+ // packages/model-core/src/runtime-fallback-auto-retry-signal.ts
8058
+ var init_runtime_fallback_auto_retry_signal = () => {};
8059
+
8060
+ // packages/model-core/src/runtime-fallback-error-shape.ts
8061
+ var init_runtime_fallback_error_shape = () => {};
8062
+
8063
+ // packages/model-core/src/runtime-fallback-error-classifier.ts
8064
+ var init_runtime_fallback_error_classifier = () => {};
8065
+
8043
8066
  // packages/model-core/src/model-error-classifier.ts
8044
- var RETRYABLE_ERROR_NAMES, STOP_ERROR_NAMES, NON_RETRYABLE_ERROR_NAMES;
8067
+ var RETRYABLE_ERROR_NAMES, NON_RETRYABLE_ERROR_NAMES;
8045
8068
  var init_model_error_classifier = __esm(() => {
8046
8069
  RETRYABLE_ERROR_NAMES = new Set([
8047
8070
  "providermodelnotfounderror",
@@ -8050,11 +8073,6 @@ var init_model_error_classifier = __esm(() => {
8050
8073
  "providerconnectionerror",
8051
8074
  "authenticationerror"
8052
8075
  ]);
8053
- STOP_ERROR_NAMES = new Set([
8054
- "quotaexceedederror",
8055
- "insufficientcreditserror",
8056
- "freeusagelimiterror"
8057
- ]);
8058
8076
  NON_RETRYABLE_ERROR_NAMES = new Set([
8059
8077
  "messageabortederror",
8060
8078
  "permissiondeniederror",
@@ -8066,15 +8084,6 @@ var init_model_error_classifier = __esm(() => {
8066
8084
  ]);
8067
8085
  });
8068
8086
 
8069
- // packages/model-core/src/runtime-fallback-auto-retry-signal.ts
8070
- var init_runtime_fallback_auto_retry_signal = () => {};
8071
-
8072
- // packages/model-core/src/runtime-fallback-error-shape.ts
8073
- var init_runtime_fallback_error_shape = () => {};
8074
-
8075
- // packages/model-core/src/runtime-fallback-error-classifier.ts
8076
- var init_runtime_fallback_error_classifier = () => {};
8077
-
8078
8087
  // packages/model-core/src/provider-exhaustion-fallback-policy.ts
8079
8088
  var init_provider_exhaustion_fallback_policy = () => {};
8080
8089
 
@@ -74336,6 +74345,29 @@ var init_category = __esm(() => {
74336
74345
  OmoCategoriesConfigSchema = record(string2(), OmoCategoryConfigSchema);
74337
74346
  });
74338
74347
 
74348
+ // packages/omo-config-core/src/schema/computer.ts
74349
+ var positiveInteger, nonNegativeInteger, OmoComputerSettingsLayerSchema, OmoComputerSettingsSchema;
74350
+ var init_computer = __esm(() => {
74351
+ init_zod();
74352
+ positiveInteger = number2().int().positive();
74353
+ nonNegativeInteger = number2().int().nonnegative();
74354
+ OmoComputerSettingsLayerSchema = object({
74355
+ enabled: boolean2().describe("Experimental: register the computer tool in OmO Native sessions (default: on where the host is supported; false leaves it unregistered)"),
74356
+ display: string2().min(1),
74357
+ max_width: positiveInteger,
74358
+ max_height: positiveInteger,
74359
+ screenshot_max_bytes: positiveInteger,
74360
+ stop_hotkey: string2().min(1),
74361
+ allow_host_relay_only_stop: boolean2(),
74362
+ macos_canary: _enum(["session", "off"]),
74363
+ audit_log: object({ enabled: boolean2() }).partial().strict(),
74364
+ screenshot_gc: object({ enabled: boolean2(), stale_ms: nonNegativeInteger, scan_interval_ms: nonNegativeInteger }).partial().strict(),
74365
+ engine_path: string2().min(1),
74366
+ cua_adapter: boolean2()
74367
+ }).partial().strict().describe("Experimental computer use in OmO Native: screenshots, windows, accessibility trees and native mouse and keyboard input. Every key is optional; defaults depend on the host.");
74368
+ OmoComputerSettingsSchema = OmoComputerSettingsLayerSchema;
74369
+ });
74370
+
74339
74371
  // packages/omo-config-core/src/schema/git-master.ts
74340
74372
  var OmoGitMasterSettingsShape, OmoGitMasterSettingsLayerSchema, OmoGitMasterSettingsSchema;
74341
74373
  var init_git_master = __esm(() => {
@@ -74608,11 +74640,11 @@ function resolveOmoTaskSettings(input, resolveParallelism = availableParallelism
74608
74640
  const record2 = record(string2(), unknown()).parse(input);
74609
74641
  return OmoTaskSettingsSchema.parse({
74610
74642
  ...record2,
74611
- residency_max_children: record2["residency_max_children"] ?? Math.min(DEFAULT_RESIDENCY_MAX_CHILDREN, Math.max(8, resolveParallelism() * 2)),
74643
+ residency_max_children: record2["residency_max_children"] ?? DEFAULT_RESIDENCY_MAX_CHILDREN,
74612
74644
  global_concurrency: record2["global_concurrency"] ?? Math.max(8, resolveParallelism() * 2)
74613
74645
  });
74614
74646
  }
74615
- var DEFAULT_RESIDENCY_MAX_CHILDREN = 16, ResidencyMaxChildrenInputSchema, OmoTaskWaitSchema, OmoTaskTeamSettingsSchema, OmoTaskWarningsSchema, IsolationBackendKindSchema, OmoTaskIsolationSchema, isolationDefaults, OmoTaskIsolationLayerSchema, OmoTaskDagSettingsSchema, OmoTaskSettingsSchema, OmoTaskDagSettingsLayerSchema, OmoTaskWaitLayerSchema, OmoTaskTeamSettingsLayerSchema, OmoTaskWarningsLayerSchema, OmoTaskSettingsLayerSchema;
74647
+ var DEFAULT_RESIDENCY_MAX_CHILDREN = "unlimited", ResidencyMaxChildrenInputSchema, OmoTaskWaitSchema, OmoTaskTeamSettingsSchema, OmoTaskWarningsSchema, IsolationBackendKindSchema, OmoTaskIsolationSchema, isolationDefaults, OmoTaskIsolationLayerSchema, OmoTaskDagSettingsSchema, OmoTaskSettingsSchema, OmoTaskDagSettingsLayerSchema, OmoTaskWaitLayerSchema, OmoTaskTeamSettingsLayerSchema, OmoTaskWarningsLayerSchema, OmoTaskSettingsLayerSchema;
74616
74648
  var init_task = __esm(() => {
74617
74649
  init_zod();
74618
74650
  ResidencyMaxChildrenInputSchema = union([number2().int().nonnegative(), literal("unlimited")]);
@@ -74675,7 +74707,7 @@ var init_task = __esm(() => {
74675
74707
  provider_concurrency: record(string2(), number2().int().nonnegative()).optional(),
74676
74708
  model_concurrency: record(string2(), number2().int().nonnegative()).optional(),
74677
74709
  max_depth: number2().int().nonnegative().default(1),
74678
- residency_max_children: ResidencyMaxChildrenInputSchema.default(8),
74710
+ residency_max_children: ResidencyMaxChildrenInputSchema.default(DEFAULT_RESIDENCY_MAX_CHILDREN),
74679
74711
  resident_idle_timeout_ms: number2().int().positive().max(Number.MAX_SAFE_INTEGER).default(900000),
74680
74712
  ttl_ms: number2().int().positive().default(86400000),
74681
74713
  state_dir: string2().optional(),
@@ -74826,6 +74858,7 @@ var init_config = __esm(() => {
74826
74858
  init_zod();
74827
74859
  init_agent();
74828
74860
  init_category();
74861
+ init_computer();
74829
74862
  init_git_master();
74830
74863
  init_memory();
74831
74864
  init_model_catalog();
@@ -74848,6 +74881,7 @@ var init_config = __esm(() => {
74848
74881
  model_profile: string2().optional(),
74849
74882
  memory: OmoMemorySettingsLayerSchema.optional(),
74850
74883
  telemetry: OmoTelemetrySettingsLayerSchema.optional(),
74884
+ computer: OmoComputerSettingsLayerSchema.optional(),
74851
74885
  disabled_skills: OmoDisabledSkillsSchema.optional()
74852
74886
  }).strict();
74853
74887
  OmoConfigProfileSchema = object({
@@ -74862,6 +74896,7 @@ var init_config = __esm(() => {
74862
74896
  model_profile: string2().optional(),
74863
74897
  memory: OmoMemorySettingsLayerSchema.optional(),
74864
74898
  telemetry: OmoTelemetrySettingsLayerSchema.optional(),
74899
+ computer: OmoComputerSettingsLayerSchema.optional(),
74865
74900
  disabled_skills: OmoDisabledSkillsSchema.optional(),
74866
74901
  "[opencode]": OmoOpenCodeHarnessConfigSchema.optional(),
74867
74902
  "[native]": OmoTypedHarnessConfigSchema.optional(),
@@ -74881,6 +74916,7 @@ var init_config = __esm(() => {
74881
74916
  model_profile: string2().optional(),
74882
74917
  memory: OmoMemorySettingsSchema.optional(),
74883
74918
  telemetry: OmoTelemetrySettingsSchema.optional(),
74919
+ computer: OmoComputerSettingsSchema.optional(),
74884
74920
  disabled_skills: OmoDisabledSkillsSchema.optional(),
74885
74921
  "[opencode]": OmoOpenCodeHarnessConfigSchema.optional(),
74886
74922
  "[native]": OmoTypedHarnessConfigSchema.optional(),
@@ -74903,6 +74939,7 @@ var init_config = __esm(() => {
74903
74939
  model_profile: string2().optional(),
74904
74940
  memory: OmoMemorySettingsLayerSchema.optional(),
74905
74941
  telemetry: OmoTelemetrySettingsLayerSchema.optional(),
74942
+ computer: OmoComputerSettingsLayerSchema.optional(),
74906
74943
  disabled_skills: OmoDisabledSkillsSchema.optional(),
74907
74944
  "[opencode]": OmoOpenCodeHarnessConfigSchema.optional(),
74908
74945
  "[native]": OmoTypedHarnessConfigSchema.optional(),
@@ -75048,6 +75085,7 @@ var init_schema = __esm(() => {
75048
75085
  init_task();
75049
75086
  init_team();
75050
75087
  init_telemetry();
75088
+ init_computer();
75051
75089
  });
75052
75090
 
75053
75091
  // packages/omo-config-core/src/loader/disabled-skills.ts
@@ -85359,7 +85397,7 @@ class SyncSpanContextManager {
85359
85397
  var init_context = () => {};
85360
85398
 
85361
85399
  // node_modules/.bun/@posthog+core@1.55.0/node_modules/@posthog/core/dist/traces/config.mjs
85362
- function positiveInteger(value, fallback) {
85400
+ function positiveInteger2(value, fallback) {
85363
85401
  return typeof value == "number" && Number.isInteger(value) && value >= 1 ? value : fallback;
85364
85402
  }
85365
85403
  function withUsableIdentityKeys(attributes) {
@@ -85394,22 +85432,22 @@ function resolveTracesConfig(config, hostResourceAttributes, logger) {
85394
85432
  const resourceAttributes = assignUserAttributes({
85395
85433
  ...hostResourceAttributes
85396
85434
  }, withUsableIdentityKeys(config?.resourceAttributes));
85397
- const maxExportBatchSize = positiveInteger(config?.maxExportBatchSize, DEFAULT_MAX_EXPORT_BATCH_SIZE);
85435
+ const maxExportBatchSize = positiveInteger2(config?.maxExportBatchSize, DEFAULT_MAX_EXPORT_BATCH_SIZE);
85398
85436
  return {
85399
85437
  serviceName: resourceAttributes?.["service.name"] ?? config?.serviceName,
85400
85438
  serviceVersion: resourceAttributes?.["service.version"] ?? config?.serviceVersion,
85401
85439
  environment: resourceAttributes?.["deployment.environment"] ?? config?.environment,
85402
85440
  resourceAttributes,
85403
85441
  beforeSpanSend: resolveBeforeSpanSend(config?.beforeSpanSend, logger),
85404
- maxAttributesPerSpan: positiveInteger(config?.maxAttributesPerSpan, DEFAULT_MAX_ATTRIBUTES_PER_SPAN),
85405
- maxEventsPerSpan: positiveInteger(config?.maxEventsPerSpan, DEFAULT_MAX_EVENTS_PER_SPAN),
85442
+ maxAttributesPerSpan: positiveInteger2(config?.maxAttributesPerSpan, DEFAULT_MAX_ATTRIBUTES_PER_SPAN),
85443
+ maxEventsPerSpan: positiveInteger2(config?.maxEventsPerSpan, DEFAULT_MAX_EVENTS_PER_SPAN),
85406
85444
  maxAttributesPerEvent: DEFAULT_MAX_ATTRIBUTES_PER_EVENT,
85407
- maxAttributeValueLength: positiveInteger(config?.maxAttributeValueLength, DEFAULT_MAX_ATTRIBUTE_VALUE_LENGTH),
85408
- flushIntervalMs: positiveInteger(config?.flushIntervalMs, DEFAULT_FLUSH_INTERVAL_MS2),
85445
+ maxAttributeValueLength: positiveInteger2(config?.maxAttributeValueLength, DEFAULT_MAX_ATTRIBUTE_VALUE_LENGTH),
85446
+ flushIntervalMs: positiveInteger2(config?.flushIntervalMs, DEFAULT_FLUSH_INTERVAL_MS2),
85409
85447
  maxExportBatchSize,
85410
- maxQueueSize: Math.max(positiveInteger(config?.maxQueueSize, DEFAULT_MAX_QUEUE_SIZE), maxExportBatchSize),
85411
- maxLiveSpans: positiveInteger(config?.maxLiveSpans, DEFAULT_MAX_LIVE_SPANS),
85412
- maxSpanAgeMs: positiveInteger(config?.maxSpanAgeMs, DEFAULT_MAX_SPAN_AGE_MS)
85448
+ maxQueueSize: Math.max(positiveInteger2(config?.maxQueueSize, DEFAULT_MAX_QUEUE_SIZE), maxExportBatchSize),
85449
+ maxLiveSpans: positiveInteger2(config?.maxLiveSpans, DEFAULT_MAX_LIVE_SPANS),
85450
+ maxSpanAgeMs: positiveInteger2(config?.maxSpanAgeMs, DEFAULT_MAX_SPAN_AGE_MS)
85413
85451
  };
85414
85452
  }
85415
85453
  var DEFAULT_FLUSH_INTERVAL_MS2 = 5000, DEFAULT_MAX_EXPORT_BATCH_SIZE = 512, DEFAULT_MAX_QUEUE_SIZE = 2048, DEFAULT_MAX_ATTRIBUTES_PER_SPAN = 128, DEFAULT_MAX_EVENTS_PER_SPAN = 128, DEFAULT_MAX_ATTRIBUTES_PER_EVENT = 128, DEFAULT_MAX_ATTRIBUTE_VALUE_LENGTH = 8192, DEFAULT_MAX_LIVE_SPANS = 1e4, DEFAULT_MAX_SPAN_AGE_MS = 3600000, IDENTITY_KEYS;
@@ -88949,7 +88987,7 @@ var package_default2;
88949
88987
  var init_package2 = __esm(() => {
88950
88988
  package_default2 = {
88951
88989
  name: "@oh-my-opencode/omo-codex",
88952
- version: "5.0.1",
88990
+ version: "5.1.0",
88953
88991
  type: "module",
88954
88992
  private: true,
88955
88993
  description: "Codex harness adapter for oh-my-openagent. Vendored Codex plugin namespace (omo) + TypeScript installer + telemetry.",
@@ -98099,6 +98137,8 @@ function isErrno(error, code) {
98099
98137
  var REQUIRED_PLUGIN_ARTIFACTS = [
98100
98138
  join62("extensions", "omo.js"),
98101
98139
  join62("extensions", "omo-task.js"),
98140
+ join62("extensions", "omo-computer-use.js"),
98141
+ join62("extensions", "assets.generated.json"),
98102
98142
  join62("extensions", "omo-member.js"),
98103
98143
  join62("extensions", "memory-run-supervisor.mjs"),
98104
98144
  ...PERSONA_ASSET_FILES.map((filename) => join62("extensions", filename)),
@@ -98290,7 +98330,7 @@ async function runNativeDevInstaller(options) {
98290
98330
  return runSenpiInstaller(options);
98291
98331
  }
98292
98332
  // packages/omo-opencode/src/cli/install-native/legacy-omo-bin.ts
98293
- import { lstatSync as lstatSync4, readFileSync as readFileSync15, realpathSync as realpathSync8 } from "fs";
98333
+ import { lstatSync as lstatSync4, readFileSync as readFileSync15, realpathSync as realpathSync8, statSync as statSync4 } from "fs";
98294
98334
  import { dirname as dirname26, isAbsolute as isAbsolute12, join as join64, posix as posix9, win32 as win325 } from "path";
98295
98335
  var NATIVE_OMO_PACKAGE = "omo-ai";
98296
98336
  var LEGACY_OMO_BIN_PACKAGES = ["oh-my-openagent", "oh-my-opencode", "lazycodex"];
@@ -98372,12 +98412,11 @@ function resolveOwner(binPath) {
98372
98412
  if (fromLink !== null)
98373
98413
  return fromLink;
98374
98414
  const shim = readShimText(binPath);
98375
- if (shim === null)
98376
- return null;
98377
- const lightWrapper = codexLightWrapperOwner(shim);
98415
+ const lightWrapper = shim === null ? null : codexLightWrapperOwner(shim);
98378
98416
  if (lightWrapper !== null)
98379
98417
  return lightWrapper;
98380
- for (const entry of shimEntryPaths(shim, dirname26(binPath))) {
98418
+ const entries = [...shim === null ? [] : shimEntryPaths(shim, dirname26(binPath)), ...bunxEntryPaths(binPath)];
98419
+ for (const entry of entries) {
98381
98420
  if (!isInsideNodeModules(entry) || !pathExists(entry))
98382
98421
  continue;
98383
98422
  const owner = ownerOfFile(entry);
@@ -98398,6 +98437,23 @@ function shimEntryPaths(shim, shimDirectory) {
98398
98437
  }
98399
98438
  return paths;
98400
98439
  }
98440
+ function bunxEntryPaths(binPath) {
98441
+ if (!/\.exe$/i.test(binPath))
98442
+ return [];
98443
+ const sidecar = `${binPath.slice(0, -4)}.bunx`;
98444
+ let contents;
98445
+ try {
98446
+ if (!statSync4(sidecar).isFile())
98447
+ return [];
98448
+ contents = readFileSync15(sidecar).toString("utf16le");
98449
+ } catch {
98450
+ return [];
98451
+ }
98452
+ const end = contents.indexOf('"\x00');
98453
+ if (end <= 0)
98454
+ return [];
98455
+ return [join64(dirname26(dirname26(binPath)), contents.slice(0, end).replace(/\\/g, "/"))];
98456
+ }
98401
98457
  function codexLightWrapperOwner(shim) {
98402
98458
  if (!shim.includes(CODEX_LIGHT_WRAPPER_MARKER))
98403
98459
  return null;
@@ -103327,20 +103383,41 @@ var BOULDER_FILE = "boulder.json";
103327
103383
  var BOULDER_STATE_PATH = `${BOULDER_DIR}/${BOULDER_FILE}`;
103328
103384
  var NOTEPAD_DIR = "notepads";
103329
103385
  var NOTEPAD_BASE_PATH = `${BOULDER_DIR}/${NOTEPAD_DIR}`;
103386
+ // packages/boulder-state/src/markdown-fence.ts
103387
+ var FENCE_PATTERN = /^[ \t]{0,3}(`{3,}|~{3,})(.*)$/;
103388
+ function parseOpeningFence(line) {
103389
+ const match = line.match(FENCE_PATTERN);
103390
+ const run = match?.[1];
103391
+ const info = match?.[2];
103392
+ const marker = run?.charAt(0);
103393
+ if (run === undefined || info === undefined || marker !== "`" && marker !== "~" || marker === "`" && info.includes("`")) {
103394
+ return null;
103395
+ }
103396
+ return { marker, length: run.length };
103397
+ }
103398
+ function isClosingFence(line, fence) {
103399
+ const run = line.match(/^[ \t]{0,3}(`{3,}|~{3,})[ \t]*$/)?.[1];
103400
+ return run?.charAt(0) === fence.marker && run.length >= fence.length;
103401
+ }
103402
+
103330
103403
  // packages/boulder-state/src/plan-checklist.ts
103331
- var SIMPLE_CHECKBOX_PATTERN = /^[-*][ \t]*\[[ \t]*([xX]?)[ \t]*\][ \t]+(.+)$/;
103404
+ var SIMPLE_CHECKBOX_PATTERN = /^[-*][ \t]*\[[ \t]*([xX~]?)[ \t]*\][ \t]+(.+)$/;
103332
103405
  var TODO_HEADING_PATTERN = /^##[ \t]+TODOs(?:[ \t]+#+)?[ \t]*$/i;
103333
103406
  var FINAL_VERIFICATION_HEADING_PATTERN = /^##[ \t]+Final Verification Wave(?:[ \t]+#+)?[ \t]*$/i;
103334
103407
  var SECTION_BOUNDARY_HEADING_PATTERN = /^#{1,2}(?:[ \t]+|$)/;
103335
- var FENCE_PATTERN = /^[ \t]{0,3}(`{3,}|~{3,})(.*)$/;
103336
- var TODO_CHECKBOX_PATTERN = /^- \[([ xX])\] ([1-9]\d*\. .+)$/;
103337
- var FINAL_WAVE_CHECKBOX_PATTERN = /^- \[([ xX])\] (F[1-9]\d*\. .+)$/i;
103408
+ var STRUCTURED_CHECKBOX_PATTERN = /^- \[([ xX~])\] (.+)$/;
103409
+ var TODO_TASK_LABEL_PATTERN = /^([1-9]\d*|T[1-9]\d*(?:\.[1-9]\d*[a-z]?)?)(?:\.[ \t]+|[ \t]+(?:[-\u2014][ \t]+)?)(.+)$/i;
103410
+ var FINAL_WAVE_TASK_LABEL_PATTERN = /^([FH][1-9]\d*(?:\.[1-9]\d*[a-z]?)?)(?:\.[ \t]+|[ \t]+(?:[-\u2014][ \t]+)?)(.+)$/i;
103338
103411
  function parsePlanChecklist(markdown) {
103339
103412
  const lines = markdown.split(/\r?\n/);
103340
103413
  if (!hasStructuredSection(lines)) {
103341
103414
  return parseSimpleChecklist(lines);
103342
103415
  }
103343
- return parseStructuredPlan(lines).checklist;
103416
+ const structuredPlan = parseStructuredPlan(lines);
103417
+ if (structuredPlan.checklist.total === 0 && structuredPlan.hasUntrackedTopLevelCheckbox) {
103418
+ return parseSimpleChecklist(lines);
103419
+ }
103420
+ return structuredPlan.checklist;
103344
103421
  }
103345
103422
  function parseCurrentTopLevelTask(markdown) {
103346
103423
  const lines = markdown.split(/\r?\n/);
@@ -103350,10 +103427,12 @@ function parseCurrentTopLevelTask(markdown) {
103350
103427
  return parseStructuredPlan(lines).nextTask;
103351
103428
  }
103352
103429
  function parseStructuredPlan(lines) {
103430
+ let completed = 0;
103353
103431
  let remaining = 0;
103354
103432
  let total = 0;
103355
103433
  let nextTaskLabel = null;
103356
103434
  let nextTask = null;
103435
+ let hasUntrackedTopLevelCheckbox = false;
103357
103436
  let section = "other";
103358
103437
  let fence = null;
103359
103438
  for (const line of lines) {
@@ -103373,6 +103452,9 @@ function parseStructuredPlan(lines) {
103373
103452
  continue;
103374
103453
  }
103375
103454
  if (section === "other") {
103455
+ if (parseSimpleTopLevelCheckbox(line) !== null) {
103456
+ hasUntrackedTopLevelCheckbox = true;
103457
+ }
103376
103458
  continue;
103377
103459
  }
103378
103460
  const checkbox = parseStructuredTopLevelCheckbox(line, section);
@@ -103380,7 +103462,11 @@ function parseStructuredPlan(lines) {
103380
103462
  continue;
103381
103463
  }
103382
103464
  total += 1;
103383
- if (checkbox.checked) {
103465
+ if (checkbox.status === "done") {
103466
+ completed += 1;
103467
+ continue;
103468
+ }
103469
+ if (checkbox.status === "in-progress") {
103384
103470
  continue;
103385
103471
  }
103386
103472
  remaining += 1;
@@ -103391,15 +103477,17 @@ function parseStructuredPlan(lines) {
103391
103477
  }
103392
103478
  return {
103393
103479
  checklist: {
103394
- completed: total - remaining,
103480
+ completed,
103395
103481
  remaining,
103396
103482
  total,
103397
103483
  nextTaskLabel
103398
103484
  },
103399
- nextTask
103485
+ nextTask,
103486
+ hasUntrackedTopLevelCheckbox
103400
103487
  };
103401
103488
  }
103402
103489
  function parseSimpleChecklist(lines) {
103490
+ let completed = 0;
103403
103491
  let remaining = 0;
103404
103492
  let total = 0;
103405
103493
  let nextTaskLabel = null;
@@ -103421,7 +103509,11 @@ function parseSimpleChecklist(lines) {
103421
103509
  continue;
103422
103510
  }
103423
103511
  total += 1;
103424
- if (checkbox.checked) {
103512
+ if (checkbox.status === "done") {
103513
+ completed += 1;
103514
+ continue;
103515
+ }
103516
+ if (checkbox.status === "in-progress") {
103425
103517
  continue;
103426
103518
  }
103427
103519
  remaining += 1;
@@ -103429,7 +103521,7 @@ function parseSimpleChecklist(lines) {
103429
103521
  nextTaskLabel = checkbox.label;
103430
103522
  }
103431
103523
  }
103432
- return { completed: total - remaining, remaining, total, nextTaskLabel };
103524
+ return { completed, remaining, total, nextTaskLabel };
103433
103525
  }
103434
103526
  function parseSimpleTopLevelCheckbox(line) {
103435
103527
  const match = line.match(SIMPLE_CHECKBOX_PATTERN);
@@ -103438,7 +103530,13 @@ function parseSimpleTopLevelCheckbox(line) {
103438
103530
  if (marker === undefined || label === undefined) {
103439
103531
  return null;
103440
103532
  }
103441
- return { checked: marker.toLowerCase() === "x", label };
103533
+ return { status: parseCheckboxStatus(marker), label };
103534
+ }
103535
+ function parseCheckboxStatus(marker) {
103536
+ if (marker.toLowerCase() === "x") {
103537
+ return "done";
103538
+ }
103539
+ return marker === "~" ? "in-progress" : "open";
103442
103540
  }
103443
103541
  function hasStructuredSection(lines) {
103444
103542
  let fence = null;
@@ -103470,8 +103568,7 @@ function parseStructuredSectionHeading(line) {
103470
103568
  return "other";
103471
103569
  }
103472
103570
  function parseStructuredTopLevelCheckbox(line, section) {
103473
- const pattern = section === "todo" ? TODO_CHECKBOX_PATTERN : FINAL_WAVE_CHECKBOX_PATTERN;
103474
- const match = line.match(pattern);
103571
+ const match = line.match(STRUCTURED_CHECKBOX_PATTERN);
103475
103572
  const marker = match?.[1];
103476
103573
  const label = match?.[2];
103477
103574
  if (marker === undefined || label === undefined) {
@@ -103481,10 +103578,10 @@ function parseStructuredTopLevelCheckbox(line, section) {
103481
103578
  if (task === null) {
103482
103579
  return null;
103483
103580
  }
103484
- return { checked: marker.toLowerCase() === "x", label, task };
103581
+ return { status: parseCheckboxStatus(marker), label, task };
103485
103582
  }
103486
103583
  function buildTaskRef(section, label) {
103487
- const pattern = section === "todo" ? /^([1-9]\d*)\. (.+)$/ : /^(F[1-9]\d*)\. (.+)$/i;
103584
+ const pattern = section === "todo" ? TODO_TASK_LABEL_PATTERN : FINAL_WAVE_TASK_LABEL_PATTERN;
103488
103585
  const match = label.match(pattern);
103489
103586
  const rawLabel = match?.[1];
103490
103587
  const title = match?.[2];
@@ -103498,20 +103595,6 @@ function buildTaskRef(section, label) {
103498
103595
  title
103499
103596
  };
103500
103597
  }
103501
- function parseOpeningFence(line) {
103502
- const match = line.match(FENCE_PATTERN);
103503
- const run = match?.[1];
103504
- const info = match?.[2];
103505
- const marker = run?.charAt(0);
103506
- if (run === undefined || info === undefined || marker !== "`" && marker !== "~" || marker === "`" && info.includes("`")) {
103507
- return null;
103508
- }
103509
- return { marker, length: run.length };
103510
- }
103511
- function isClosingFence(line, fence) {
103512
- const run = line.match(/^[ \t]{0,3}(`{3,}|~{3,})[ \t]*$/)?.[1];
103513
- return run?.charAt(0) === fence.marker && run.length >= fence.length;
103514
- }
103515
103598
  // packages/boulder-state/src/top-level-task.ts
103516
103599
  import { existsSync as existsSync36, readFileSync as readFileSync19 } from "fs";
103517
103600
  function readCurrentTopLevelTask(planPath) {
@@ -103553,7 +103636,7 @@ function resolveBoulderPlanPathForWork(directory, work) {
103553
103636
  return resolveBoulderPlanPath(directory, work);
103554
103637
  }
103555
103638
  // packages/boulder-state/src/storage/plan-progress.ts
103556
- import { existsSync as existsSync38, readFileSync as readFileSync20, readdirSync as readdirSync9, statSync as statSync4 } from "fs";
103639
+ import { existsSync as existsSync38, readFileSync as readFileSync20, readdirSync as readdirSync9, statSync as statSync5 } from "fs";
103557
103640
  function getPlanProgress(planPath) {
103558
103641
  if (!existsSync38(planPath)) {
103559
103642
  return { total: 0, completed: 0, isComplete: false };
@@ -103972,7 +104055,7 @@ async function hasActiveBoulderContinuation(directory, sessionID, client) {
103972
104055
  if (!boulder || !boulder.active_plan)
103973
104056
  return false;
103974
104057
  const progress = getPlanProgress(resolveBoulderPlanPath(directory, boulder));
103975
- if (progress.isComplete)
104058
+ if (progress.isComplete || progress.total === 0)
103976
104059
  return false;
103977
104060
  if (!client)
103978
104061
  return false;
@@ -106170,13 +106253,14 @@ init_src();
106170
106253
  import { existsSync as existsSync55 } from "fs";
106171
106254
  import { createRequire as createRequire2 } from "module";
106172
106255
  import { homedir as homedir20 } from "os";
106173
- import { dirname as dirname33, join as join86 } from "path";
106256
+ import { dirname as dirname33, join as join87 } from "path";
106174
106257
 
106175
106258
  // packages/omo-opencode/src/hooks/comment-checker/downloader.ts
106176
- import { join as join85 } from "path";
106259
+ import { join as join86 } from "path";
106177
106260
  import { homedir as homedir19, tmpdir as tmpdir4 } from "os";
106178
106261
  // packages/comment-checker-core/src/release.ts
106179
106262
  import { join as join84 } from "path";
106263
+ var COMMENT_CHECKER_RELEASE_VERSION = "0.8.0";
106180
106264
  function commentCheckerBinaryName(platform) {
106181
106265
  return platform === "win32" ? "comment-checker.exe" : "comment-checker";
106182
106266
  }
@@ -106189,12 +106273,23 @@ function commentCheckerCacheDir(input) {
106189
106273
  const base = input.env.XDG_CACHE_HOME || join84(input.homedir, ".cache");
106190
106274
  return join84(base, input.cacheDirName, "bin");
106191
106275
  }
106276
+ // packages/comment-checker-core/src/cached-release.ts
106277
+ import { readFileSync as readFileSync37, writeFileSync as writeFileSync12 } from "fs";
106278
+ import { join as join85 } from "path";
106279
+ var COMMENT_CHECKER_VERSION_MARKER = "comment-checker.version";
106280
+ function isCachedCommentCheckerCurrent(cacheDir, readFile = (path) => readFileSync37(path, "utf-8")) {
106281
+ try {
106282
+ return readFile(join85(cacheDir, COMMENT_CHECKER_VERSION_MARKER)).trim() === COMMENT_CHECKER_RELEASE_VERSION;
106283
+ } catch {
106284
+ return false;
106285
+ }
106286
+ }
106192
106287
  // packages/omo-opencode/src/hooks/comment-checker/downloader.ts
106193
106288
  init_binary_downloader();
106194
106289
  init_logger2();
106195
106290
  init_plugin_identity();
106196
106291
  var DEBUG = process.env.COMMENT_CHECKER_DEBUG === "1";
106197
- var DEBUG_FILE = join85(tmpdir4(), "comment-checker-debug.log");
106292
+ var DEBUG_FILE = join86(tmpdir4(), "comment-checker-debug.log");
106198
106293
  function getCacheDir2() {
106199
106294
  return commentCheckerCacheDir({
106200
106295
  platform: process.platform,
@@ -106207,7 +106302,9 @@ function getBinaryName() {
106207
106302
  return commentCheckerBinaryName(process.platform);
106208
106303
  }
106209
106304
  function getCachedBinaryPath2() {
106210
- return getCachedBinaryPath(getCacheDir2(), getBinaryName());
106305
+ const cacheDir = getCacheDir2();
106306
+ const cached = getCachedBinaryPath(cacheDir, getBinaryName());
106307
+ return cached !== null && isCachedCommentCheckerCurrent(cacheDir) ? cached : null;
106211
106308
  }
106212
106309
 
106213
106310
  // packages/omo-opencode/src/cli/doctor/checks/dependencies.ts
@@ -106251,7 +106348,7 @@ async function getBinaryVersion(binary) {
106251
106348
  }
106252
106349
  }
106253
106350
  async function checkAstGrepCli() {
106254
- const runtimeDir = astGrepRuntimeDir(join86(homedir20(), ".omo"));
106351
+ const runtimeDir = astGrepRuntimeDir(join87(homedir20(), ".omo"));
106255
106352
  const sgPath = findSgBinarySync({ runtimeDir });
106256
106353
  if (sgPath === null) {
106257
106354
  return {
@@ -106281,10 +106378,10 @@ function findCommentCheckerPackageBinary(baseDirOverride, resolvePackageJsonPath
106281
106378
  const platformKey = `${process.platform}-${process.arch === "x64" ? "x64" : process.arch}`;
106282
106379
  try {
106283
106380
  const packageDir = baseDirOverride ?? dirname33(resolvePackageJsonPath());
106284
- const vendorPath = join86(packageDir, "vendor", platformKey, binaryName);
106381
+ const vendorPath = join87(packageDir, "vendor", platformKey, binaryName);
106285
106382
  if (existsSync55(vendorPath))
106286
106383
  return vendorPath;
106287
- const binPath = join86(packageDir, "bin", binaryName);
106384
+ const binPath = join87(packageDir, "bin", binaryName);
106288
106385
  if (existsSync55(binPath))
106289
106386
  return binPath;
106290
106387
  } catch (error) {
@@ -106431,7 +106528,7 @@ async function getGhCliInfo(dependencies = {}) {
106431
106528
  // packages/omo-opencode/src/mcp/lsp.ts
106432
106529
  init_zod();
106433
106530
  init_opencode_config_dir();
106434
- import { existsSync as existsSync56, readFileSync as readFileSync37 } from "fs";
106531
+ import { existsSync as existsSync56, readFileSync as readFileSync38 } from "fs";
106435
106532
  import { delimiter as delimiter3, dirname as dirname34, resolve as resolve23 } from "path";
106436
106533
  import { fileURLToPath as fileURLToPath7 } from "url";
106437
106534
 
@@ -106575,7 +106672,7 @@ function findBootstrapRoot(candidates, pathExists) {
106575
106672
  }
106576
106673
  function readDaemonPackageVersion(root) {
106577
106674
  try {
106578
- const packageJson = JSON.parse(readFileSync37(resolve23(root, PACKAGE_REL, "package.json"), "utf-8"));
106675
+ const packageJson = JSON.parse(readFileSync38(resolve23(root, PACKAGE_REL, "package.json"), "utf-8"));
106579
106676
  return DaemonPackageSchema.parse(packageJson).version;
106580
106677
  } catch (error) {
106581
106678
  if (!(error instanceof Error))
@@ -106658,15 +106755,15 @@ function getInstalledLspServers(options = {}) {
106658
106755
 
106659
106756
  // packages/omo-opencode/src/cli/doctor/checks/tools-mcp.ts
106660
106757
  init_shared();
106661
- import { existsSync as existsSync57, readFileSync as readFileSync38 } from "fs";
106758
+ import { existsSync as existsSync57, readFileSync as readFileSync39 } from "fs";
106662
106759
  import { homedir as homedir21 } from "os";
106663
- import { join as join87 } from "path";
106760
+ import { join as join88 } from "path";
106664
106761
  var BUILTIN_MCP_SERVERS = ["websearch", "context7", "grep_app", "lsp"];
106665
106762
  function getMcpConfigPaths() {
106666
106763
  return [
106667
- join87(homedir21(), ".claude", ".mcp.json"),
106668
- join87(process.cwd(), ".mcp.json"),
106669
- join87(process.cwd(), ".claude", ".mcp.json")
106764
+ join88(homedir21(), ".claude", ".mcp.json"),
106765
+ join88(process.cwd(), ".mcp.json"),
106766
+ join88(process.cwd(), ".claude", ".mcp.json")
106670
106767
  ];
106671
106768
  }
106672
106769
  function loadUserMcpConfig() {
@@ -106675,7 +106772,7 @@ function loadUserMcpConfig() {
106675
106772
  if (!existsSync57(configPath))
106676
106773
  continue;
106677
106774
  try {
106678
- const content = readFileSync38(configPath, "utf-8");
106775
+ const content = readFileSync39(configPath, "utf-8");
106679
106776
  const config = parseJsonc(content);
106680
106777
  if (config.mcpServers) {
106681
106778
  Object.assign(servers, config.mcpServers);
@@ -106810,7 +106907,7 @@ async function checkTools() {
106810
106907
 
106811
106908
  // packages/omo-opencode/src/cli/doctor/checks/telemetry.ts
106812
106909
  init_src5();
106813
- import { existsSync as existsSync58, readFileSync as readFileSync39 } from "fs";
106910
+ import { existsSync as existsSync58, readFileSync as readFileSync40 } from "fs";
106814
106911
  function isTelemetryState(value) {
106815
106912
  return value !== null && typeof value === "object" && !Array.isArray(value);
106816
106913
  }
@@ -106820,7 +106917,7 @@ function readLastActiveDay(stateFilePath) {
106820
106917
  }
106821
106918
  let parsed;
106822
106919
  try {
106823
- parsed = JSON.parse(readFileSync39(stateFilePath, "utf-8"));
106920
+ parsed = JSON.parse(readFileSync40(stateFilePath, "utf-8"));
106824
106921
  } catch (error) {
106825
106922
  if (error instanceof Error) {
106826
106923
  return "unreadable";
@@ -106948,7 +107045,7 @@ init_src();
106948
107045
  import { existsSync as existsSync59 } from "fs";
106949
107046
  import { lstat as lstat16, readdir as readdir14, readFile as readFile28 } from "fs/promises";
106950
107047
  import { homedir as homedir23 } from "os";
106951
- import { basename as basename12, join as join88, resolve as resolve24 } from "path";
107048
+ import { basename as basename12, join as join89, resolve as resolve24 } from "path";
106952
107049
  // packages/omo-opencode/package.json
106953
107050
  var package_default3 = {
106954
107051
  name: "@oh-my-opencode/omo-opencode",
@@ -107018,13 +107115,13 @@ var CODEX_BIN_NAMES = [
107018
107115
  "omo-git-bash-hook"
107019
107116
  ];
107020
107117
  async function gatherCodexSummary(deps = {}) {
107021
- const codexHome = resolve24(deps.codexHome ?? process.env.CODEX_HOME ?? join88(homedir23(), ".codex"));
107118
+ const codexHome = resolve24(deps.codexHome ?? process.env.CODEX_HOME ?? join89(homedir23(), ".codex"));
107022
107119
  const binDir = resolveCodexInstallerBinDir({ binDir: deps.binDir, codexHome, env: process.env });
107023
107120
  const detection = await (deps.detectCodexInstallation ?? detectCodexInstallation)();
107024
107121
  const pluginRoot = await resolveInstalledPluginRoot(codexHome);
107025
- const manifest = pluginRoot === null ? null : await readJson(join88(pluginRoot, ".codex-plugin", "plugin.json"));
107026
- const installSnapshot = pluginRoot === null ? null : await readJson(join88(pluginRoot, "lazycodex-install.json"));
107027
- const configPath = join88(codexHome, "config.toml");
107122
+ const manifest = pluginRoot === null ? null : await readJson(join89(pluginRoot, ".codex-plugin", "plugin.json"));
107123
+ const installSnapshot = pluginRoot === null ? null : await readJson(join89(pluginRoot, "lazycodex-install.json"));
107124
+ const configPath = join89(codexHome, "config.toml");
107028
107125
  const pluginVersion = stringField(manifest, "version");
107029
107126
  return {
107030
107127
  codexPath: detection.found && "path" in detection ? detection.path : null,
@@ -107081,7 +107178,7 @@ function buildCodexIssues(summary) {
107081
107178
  if (summary.pluginRoot === null) {
107082
107179
  issues.push({
107083
107180
  title: "OMO Codex plugin is not installed",
107084
- description: `Expected cached plugin at ${join88("plugins", "cache", MARKETPLACE_NAME, PLUGIN_NAME2, DEFAULT_PLUGIN_VERSION)} under CODEX_HOME.`,
107181
+ description: `Expected cached plugin at ${join89("plugins", "cache", MARKETPLACE_NAME, PLUGIN_NAME2, DEFAULT_PLUGIN_VERSION)} under CODEX_HOME.`,
107085
107182
  fix: "Run: npx lazycodex-ai install",
107086
107183
  severity: "error",
107087
107184
  affects: ["plugin loading"]
@@ -107146,12 +107243,12 @@ function buildCodexIssues(summary) {
107146
107243
  return issues;
107147
107244
  }
107148
107245
  async function resolveInstalledPluginRoot(codexHome) {
107149
- const pluginRoot = join88(codexHome, "plugins", "cache", MARKETPLACE_NAME, PLUGIN_NAME2);
107246
+ const pluginRoot = join89(codexHome, "plugins", "cache", MARKETPLACE_NAME, PLUGIN_NAME2);
107150
107247
  if (!existsSync59(pluginRoot))
107151
107248
  return null;
107152
107249
  const versions = await readdir14(pluginRoot, { withFileTypes: true });
107153
107250
  const candidates = versions.filter((entry) => entry.isDirectory()).map((entry) => entry.name).sort(compareVersionsDescending);
107154
- return candidates.length === 0 ? null : join88(pluginRoot, candidates[0] ?? DEFAULT_PLUGIN_VERSION);
107251
+ return candidates.length === 0 ? null : join89(pluginRoot, candidates[0] ?? DEFAULT_PLUGIN_VERSION);
107155
107252
  }
107156
107253
  async function readCodexConfigSummary(configPath) {
107157
107254
  if (!existsSync59(configPath)) {
@@ -107179,13 +107276,13 @@ async function readCodexConfigSummary(configPath) {
107179
107276
  async function readLinkedBins(binDir) {
107180
107277
  const linked = [];
107181
107278
  for (const name of CODEX_BIN_NAMES) {
107182
- if (await pathExists3(join88(binDir, process.platform === "win32" ? `${name}.cmd` : name)))
107279
+ if (await pathExists3(join89(binDir, process.platform === "win32" ? `${name}.cmd` : name)))
107183
107280
  linked.push(name);
107184
107281
  }
107185
107282
  return linked;
107186
107283
  }
107187
107284
  async function readLinkedAgents(codexHome) {
107188
- const agentsDir = join88(codexHome, "agents");
107285
+ const agentsDir = join89(codexHome, "agents");
107189
107286
  if (!existsSync59(agentsDir))
107190
107287
  return [];
107191
107288
  const entries = await readdir14(agentsDir, { withFileTypes: true });
@@ -107319,7 +107416,7 @@ function resolveLatestVersion(input) {
107319
107416
  init_src();
107320
107417
  import { readdir as readdir15, readFile as readFile29, stat as stat7 } from "fs/promises";
107321
107418
  import { homedir as homedir24 } from "os";
107322
- import { dirname as dirname35, isAbsolute as isAbsolute14, join as join89, relative as relative9, resolve as resolve25, sep as sep9 } from "path";
107419
+ import { dirname as dirname35, isAbsolute as isAbsolute14, join as join90, relative as relative9, resolve as resolve25, sep as sep9 } from "path";
107323
107420
  var CODEX_COMPONENTS_CHECK_ID = "codex-components";
107324
107421
  var CODEX_COMPONENTS_CHECK_NAME = "codex-components";
107325
107422
  var PLUGIN_DATA_DIR_NAME = "omo-sisyphuslabs";
@@ -107329,7 +107426,7 @@ async function checkCodexComponents(deps = {}) {
107329
107426
  const env = deps.env ?? process.env;
107330
107427
  const platform = deps.platform ?? process.platform;
107331
107428
  const arch = deps.arch ?? process.arch;
107332
- const codexHome = resolve25(deps.codexHome ?? env["CODEX_HOME"] ?? join89(homedir24(), ".codex"));
107429
+ const codexHome = resolve25(deps.codexHome ?? env["CODEX_HOME"] ?? join90(homedir24(), ".codex"));
107333
107430
  const summary = await gatherCodexSummary({ ...deps, codexHome });
107334
107431
  if (summary.pluginRoot === null) {
107335
107432
  return {
@@ -107354,7 +107451,7 @@ async function checkCodexComponents(deps = {}) {
107354
107451
  });
107355
107452
  }
107356
107453
  const runtimeSgDir = runtimeSgDirectory(codexHome, platform, arch);
107357
- const runtimeSgPath = join89(runtimeSgDir, sgBinaryName(platform));
107454
+ const runtimeSgPath = join90(runtimeSgDir, sgBinaryName(platform));
107358
107455
  const sg = findSgBinarySync({
107359
107456
  arch,
107360
107457
  env,
@@ -107466,7 +107563,7 @@ async function findManifestPaths(root, manifestName) {
107466
107563
  for (const entry of entries) {
107467
107564
  if (entry.name === "node_modules" || entry.name === ".git")
107468
107565
  continue;
107469
- const entryPath = join89(root, entry.name);
107566
+ const entryPath = join90(root, entry.name);
107470
107567
  if (entry.isDirectory()) {
107471
107568
  paths.push(...await findManifestPaths(entryPath, manifestName));
107472
107569
  continue;
@@ -107510,18 +107607,18 @@ function isPluginRuntimePathArg(arg) {
107510
107607
  return normalized.endsWith(".js") && normalized.includes("/dist/") && (normalized.startsWith("./") || normalized.startsWith("../") || normalized.startsWith("components/") || normalized.startsWith("/") || isAbsolute14(arg));
107511
107608
  }
107512
107609
  function runtimeSgDirectory(codexHome, platform, arch) {
107513
- return join89(codexHome, "runtime", "ast-grep", runtimeSlug(platform, arch));
107610
+ return join90(codexHome, "runtime", "ast-grep", runtimeSlug(platform, arch));
107514
107611
  }
107515
107612
  function describeSgSource(sgPath, env, runtimeSgDir, platform) {
107516
107613
  const override = env[SG_PATH_ENV_KEY]?.trim();
107517
107614
  if (override !== undefined && override.length > 0 && sgPath === override)
107518
107615
  return `env override ${SG_PATH_ENV_KEY}`;
107519
- if (sgPath === join89(runtimeSgDir, sgBinaryName(platform)))
107616
+ if (sgPath === join90(runtimeSgDir, sgBinaryName(platform)))
107520
107617
  return "runtime dir";
107521
107618
  return "PATH";
107522
107619
  }
107523
107620
  async function readBootstrapStateSummary(codexHome) {
107524
- const statePath = join89(codexHome, "plugins", "data", PLUGIN_DATA_DIR_NAME, "bootstrap", "state.json");
107621
+ const statePath = join90(codexHome, "plugins", "data", PLUGIN_DATA_DIR_NAME, "bootstrap", "state.json");
107525
107622
  const raw = await readJson2(statePath);
107526
107623
  if (raw === null)
107527
107624
  return null;
@@ -107600,16 +107697,16 @@ function isRecord18(value) {
107600
107697
  import { existsSync as existsSync60 } from "fs";
107601
107698
  import { readFile as readFile30 } from "fs/promises";
107602
107699
  import { homedir as homedir25 } from "os";
107603
- import { join as join90, resolve as resolve26 } from "path";
107700
+ import { join as join91, resolve as resolve26 } from "path";
107604
107701
  var RUNTIME_WRAPPER_MARKER2 = "OMO_GENERATED_RUNTIME_WRAPPER";
107605
107702
  var CHECK_NAME = "codex-runtime-wrapper";
107606
107703
  var REINSTALL_COMMAND = "npx --yes lazycodex-ai@latest install --no-tui";
107607
107704
  async function checkCodexRuntimeWrapper(deps = {}) {
107608
- const codexHome = resolve26(deps.codexHome ?? process.env.CODEX_HOME ?? join90(homedir25(), ".codex"));
107705
+ const codexHome = resolve26(deps.codexHome ?? process.env.CODEX_HOME ?? join91(homedir25(), ".codex"));
107609
107706
  const binDir = resolveCodexInstallerBinDir({ binDir: deps.binDir, codexHome, env: process.env });
107610
107707
  const platform = deps.platform ?? process.platform;
107611
- const wrapperPath = join90(binDir, platform === "win32" ? "omo-agent-toolkit.cmd" : "omo-agent-toolkit");
107612
- const legacyWrapperPath = join90(binDir, platform === "win32" ? "omo.cmd" : "omo");
107708
+ const wrapperPath = join91(binDir, platform === "win32" ? "omo-agent-toolkit.cmd" : "omo-agent-toolkit");
107709
+ const legacyWrapperPath = join91(binDir, platform === "win32" ? "omo.cmd" : "omo");
107613
107710
  const [wrapper, legacyWrapper] = await Promise.all([readRuntimeWrapper(wrapperPath), readRuntimeWrapper(legacyWrapperPath)]);
107614
107711
  const issues = [];
107615
107712
  if (wrapper?.includes(RUNTIME_WRAPPER_MARKER2) === true) {
@@ -108140,17 +108237,17 @@ import {
108140
108237
  existsSync as existsSync63,
108141
108238
  mkdirSync as mkdirSync17,
108142
108239
  readdirSync as readdirSync13,
108143
- readFileSync as readFileSync41,
108240
+ readFileSync as readFileSync42,
108144
108241
  renameSync as renameSync8,
108145
108242
  unlinkSync as unlinkSync9,
108146
- writeFileSync as writeFileSync13
108243
+ writeFileSync as writeFileSync14
108147
108244
  } from "fs";
108148
- import { basename as basename13, dirname as dirname36, join as join93 } from "path";
108245
+ import { basename as basename13, dirname as dirname36, join as join94 } from "path";
108149
108246
 
108150
108247
  // packages/mcp-client-core/src/config-dir.ts
108151
108248
  import { existsSync as existsSync61, realpathSync as realpathSync10 } from "fs";
108152
108249
  import { homedir as homedir26 } from "os";
108153
- import { join as join91, resolve as resolve27 } from "path";
108250
+ import { join as join92, resolve as resolve27 } from "path";
108154
108251
  function resolveConfigPath2(pathValue) {
108155
108252
  const resolvedPath = resolve27(pathValue);
108156
108253
  if (!existsSync61(resolvedPath))
@@ -108168,13 +108265,13 @@ function getOpenCodeCliConfigDir(env = process.env) {
108168
108265
  if (customConfigDir) {
108169
108266
  return resolveConfigPath2(customConfigDir);
108170
108267
  }
108171
- const xdgConfigDir = env["XDG_CONFIG_HOME"]?.trim() || join91(homedir26(), ".config");
108172
- return resolveConfigPath2(join91(xdgConfigDir, "opencode"));
108268
+ const xdgConfigDir = env["XDG_CONFIG_HOME"]?.trim() || join92(homedir26(), ".config");
108269
+ return resolveConfigPath2(join92(xdgConfigDir, "opencode"));
108173
108270
  }
108174
108271
 
108175
108272
  // packages/mcp-client-core/src/mcp-oauth/storage-index.ts
108176
- import { chmodSync as chmodSync4, existsSync as existsSync62, readFileSync as readFileSync40, renameSync as renameSync7, writeFileSync as writeFileSync12 } from "fs";
108177
- import { join as join92 } from "path";
108273
+ import { chmodSync as chmodSync4, existsSync as existsSync62, readFileSync as readFileSync41, renameSync as renameSync7, writeFileSync as writeFileSync13 } from "fs";
108274
+ import { join as join93 } from "path";
108178
108275
  var INDEX_FILE_NAME = "index.json";
108179
108276
  function isTokenIndex(value) {
108180
108277
  if (typeof value !== "object" || value === null || Array.isArray(value))
@@ -108182,14 +108279,14 @@ function isTokenIndex(value) {
108182
108279
  return Object.values(value).every((entry) => typeof entry === "string");
108183
108280
  }
108184
108281
  function getIndexPath(storageDir) {
108185
- return join92(storageDir, INDEX_FILE_NAME);
108282
+ return join93(storageDir, INDEX_FILE_NAME);
108186
108283
  }
108187
108284
  function readTokenIndex(storageDir) {
108188
108285
  const indexPath = getIndexPath(storageDir);
108189
108286
  if (!existsSync62(indexPath))
108190
108287
  return {};
108191
108288
  try {
108192
- const parsed = JSON.parse(readFileSync40(indexPath, "utf-8"));
108289
+ const parsed = JSON.parse(readFileSync41(indexPath, "utf-8"));
108193
108290
  return isTokenIndex(parsed) ? parsed : {};
108194
108291
  } catch (readError) {
108195
108292
  if (!(readError instanceof Error))
@@ -108201,7 +108298,7 @@ function writeTokenIndex(storageDir, index) {
108201
108298
  try {
108202
108299
  const indexPath = getIndexPath(storageDir);
108203
108300
  const tempPath = `${indexPath}.tmp.${Date.now()}`;
108204
- writeFileSync12(tempPath, JSON.stringify(index, null, 2), { encoding: "utf-8", mode: 384 });
108301
+ writeFileSync13(tempPath, JSON.stringify(index, null, 2), { encoding: "utf-8", mode: 384 });
108205
108302
  chmodSync4(tempPath, 384);
108206
108303
  renameSync7(tempPath, indexPath);
108207
108304
  return true;
@@ -108226,16 +108323,16 @@ function deleteTokenIndexEntry(storageDir, hash) {
108226
108323
  var STORAGE_DIR_NAME = "mcp-oauth";
108227
108324
  var LEGACY_STORAGE_FILE_NAME = "mcp-oauth.json";
108228
108325
  function getMcpOauthStorageDir() {
108229
- return join93(getOpenCodeCliConfigDir(), STORAGE_DIR_NAME);
108326
+ return join94(getOpenCodeCliConfigDir(), STORAGE_DIR_NAME);
108230
108327
  }
108231
108328
  function getMcpOauthServerHash(serverHost, resource) {
108232
108329
  return createHash7("sha256").update(buildKey(serverHost, resource)).digest("hex").slice(0, 32);
108233
108330
  }
108234
108331
  function getMcpOauthStoragePath(serverHost, resource) {
108235
- return join93(getMcpOauthStorageDir(), `${getMcpOauthServerHash(serverHost, resource)}.json`);
108332
+ return join94(getMcpOauthStorageDir(), `${getMcpOauthServerHash(serverHost, resource)}.json`);
108236
108333
  }
108237
108334
  function getLegacyStoragePath() {
108238
- return join93(getOpenCodeCliConfigDir(), LEGACY_STORAGE_FILE_NAME);
108335
+ return join94(getOpenCodeCliConfigDir(), LEGACY_STORAGE_FILE_NAME);
108239
108336
  }
108240
108337
  function normalizeHost2(serverHost) {
108241
108338
  let host = serverHost.trim();
@@ -108299,7 +108396,7 @@ function readTokenFile(filePath) {
108299
108396
  if (!existsSync63(filePath))
108300
108397
  return null;
108301
108398
  try {
108302
- const parsed = JSON.parse(readFileSync41(filePath, "utf-8"));
108399
+ const parsed = JSON.parse(readFileSync42(filePath, "utf-8"));
108303
108400
  return isOAuthTokenData(parsed) ? parsed : null;
108304
108401
  } catch (readError) {
108305
108402
  if (!(readError instanceof Error))
@@ -108312,7 +108409,7 @@ function readLegacyStore() {
108312
108409
  if (!existsSync63(filePath))
108313
108410
  return null;
108314
108411
  try {
108315
- const parsed = JSON.parse(readFileSync41(filePath, "utf-8"));
108412
+ const parsed = JSON.parse(readFileSync42(filePath, "utf-8"));
108316
108413
  if (typeof parsed !== "object" || parsed === null || Array.isArray(parsed))
108317
108414
  return null;
108318
108415
  const result = {};
@@ -108334,7 +108431,7 @@ function writeTokenFile(filePath, token) {
108334
108431
  mkdirSync17(dir, { recursive: true });
108335
108432
  }
108336
108433
  const tempPath = `${filePath}.tmp.${Date.now()}`;
108337
- writeFileSync13(tempPath, JSON.stringify(token, null, 2), { encoding: "utf-8", mode: 384 });
108434
+ writeFileSync14(tempPath, JSON.stringify(token, null, 2), { encoding: "utf-8", mode: 384 });
108338
108435
  chmodSync5(tempPath, 384);
108339
108436
  renameSync8(tempPath, filePath);
108340
108437
  return true;
@@ -108390,7 +108487,7 @@ function deleteLegacyToken(serverHost, resource) {
108390
108487
  function writeLegacyStore(store) {
108391
108488
  try {
108392
108489
  const filePath = getLegacyStoragePath();
108393
- writeFileSync13(filePath, JSON.stringify(store, null, 2), { encoding: "utf-8", mode: 384 });
108490
+ writeFileSync14(filePath, JSON.stringify(store, null, 2), { encoding: "utf-8", mode: 384 });
108394
108491
  chmodSync5(filePath, 384);
108395
108492
  return true;
108396
108493
  } catch (writeError) {
@@ -108414,7 +108511,7 @@ function listTokensByHost(serverHost) {
108414
108511
  for (const [hash, indexedKey] of Object.entries(index)) {
108415
108512
  if (!indexedKey.startsWith(prefix))
108416
108513
  continue;
108417
- const indexedToken = readTokenFile(join93(getMcpOauthStorageDir(), `${hash}.json`));
108514
+ const indexedToken = readTokenFile(join94(getMcpOauthStorageDir(), `${hash}.json`));
108418
108515
  if (indexedToken)
108419
108516
  result[indexedKey] = indexedToken;
108420
108517
  }
@@ -108429,7 +108526,7 @@ function listAllTokens() {
108429
108526
  for (const entry of readdirSync13(dir, { withFileTypes: true })) {
108430
108527
  if (!entry.isFile() || !entry.name.endsWith(".json") || entry.name === "index.json")
108431
108528
  continue;
108432
- const token = readTokenFile(join93(dir, entry.name));
108529
+ const token = readTokenFile(join94(dir, entry.name));
108433
108530
  const hash = basename13(entry.name, ".json");
108434
108531
  if (token)
108435
108532
  result[index[hash] ?? hash] = token;
@@ -109153,7 +109250,7 @@ async function boulder(options) {
109153
109250
  }
109154
109251
  // packages/omo-opencode/src/cli/codex-ulw-loop.ts
109155
109252
  import { spawn as spawn5 } from "child_process";
109156
- import { existsSync as existsSync65, readFileSync as readFileSync42, realpathSync as realpathSync11 } from "fs";
109253
+ import { existsSync as existsSync65, readFileSync as readFileSync43, realpathSync as realpathSync11 } from "fs";
109157
109254
  import { homedir as homedir27 } from "os";
109158
109255
  var ULW_LOOP_DELEGATION_SENTINEL = "OMO_ULW_LOOP_DELEGATED";
109159
109256
  function resolveCodexUlwLoopCommand(input = {}) {
@@ -109203,7 +109300,7 @@ function resolveLegacyLocalOmoBin(env, homeDir, currentExecutablePaths) {
109203
109300
  }
109204
109301
  function isGeneratedRuntimeWrapper(candidate) {
109205
109302
  try {
109206
- return readFileSync42(candidate, "utf8").includes(RUNTIME_WRAPPER_MARKER);
109303
+ return readFileSync43(candidate, "utf8").includes(RUNTIME_WRAPPER_MARKER);
109207
109304
  } catch (error) {
109208
109305
  if (error instanceof Error)
109209
109306
  return false;