oh-my-codex 0.15.3 → 0.16.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.
- package/Cargo.lock +10 -7
- package/Cargo.toml +1 -1
- package/README.md +3 -0
- package/crates/omx-explore/Cargo.toml +3 -0
- package/crates/omx-explore/src/main.rs +517 -16
- package/dist/autoresearch/goal.d.ts +90 -0
- package/dist/autoresearch/goal.d.ts.map +1 -0
- package/dist/autoresearch/goal.js +237 -0
- package/dist/autoresearch/goal.js.map +1 -0
- package/dist/autoresearch/skill-validation.d.ts +1 -0
- package/dist/autoresearch/skill-validation.d.ts.map +1 -1
- package/dist/autoresearch/skill-validation.js +10 -3
- package/dist/autoresearch/skill-validation.js.map +1 -1
- package/dist/catalog/__tests__/generator.test.js +9 -4
- package/dist/catalog/__tests__/generator.test.js.map +1 -1
- package/dist/catalog/__tests__/plugin-bundle-ssot.test.js +20 -1
- package/dist/catalog/__tests__/plugin-bundle-ssot.test.js.map +1 -1
- package/dist/catalog/__tests__/schema.test.js +14 -3
- package/dist/catalog/__tests__/schema.test.js.map +1 -1
- package/dist/catalog/schema.js +1 -1
- package/dist/catalog/schema.js.map +1 -1
- package/dist/cli/__tests__/autoresearch-goal.test.d.ts +2 -0
- package/dist/cli/__tests__/autoresearch-goal.test.d.ts.map +1 -0
- package/dist/cli/__tests__/autoresearch-goal.test.js +194 -0
- package/dist/cli/__tests__/autoresearch-goal.test.js.map +1 -0
- package/dist/cli/__tests__/cleanup.test.js +82 -1
- package/dist/cli/__tests__/cleanup.test.js.map +1 -1
- package/dist/cli/__tests__/codex-plugin-layout.test.js +7 -4
- package/dist/cli/__tests__/codex-plugin-layout.test.js.map +1 -1
- package/dist/cli/__tests__/doctor-warning-copy.test.js +23 -0
- package/dist/cli/__tests__/doctor-warning-copy.test.js.map +1 -1
- package/dist/cli/__tests__/explore.test.js +8 -1
- package/dist/cli/__tests__/explore.test.js.map +1 -1
- package/dist/cli/__tests__/index.test.js +82 -3
- package/dist/cli/__tests__/index.test.js.map +1 -1
- package/dist/cli/__tests__/launch-fallback.test.js +58 -0
- package/dist/cli/__tests__/launch-fallback.test.js.map +1 -1
- package/dist/cli/__tests__/native-assets.test.js +26 -1
- package/dist/cli/__tests__/native-assets.test.js.map +1 -1
- package/dist/cli/__tests__/package-bin-contract.test.js +2 -2
- package/dist/cli/__tests__/package-bin-contract.test.js.map +1 -1
- package/dist/cli/__tests__/performance-goal.test.d.ts +2 -0
- package/dist/cli/__tests__/performance-goal.test.d.ts.map +1 -0
- package/dist/cli/__tests__/performance-goal.test.js +144 -0
- package/dist/cli/__tests__/performance-goal.test.js.map +1 -0
- package/dist/cli/__tests__/question.test.js +8 -0
- package/dist/cli/__tests__/question.test.js.map +1 -1
- package/dist/cli/__tests__/ralph-goal-mode-contract.test.d.ts +2 -0
- package/dist/cli/__tests__/ralph-goal-mode-contract.test.d.ts.map +1 -0
- package/dist/cli/__tests__/ralph-goal-mode-contract.test.js +31 -0
- package/dist/cli/__tests__/ralph-goal-mode-contract.test.js.map +1 -0
- package/dist/cli/__tests__/ralph-prd-deep-interview.test.js +5 -4
- package/dist/cli/__tests__/ralph-prd-deep-interview.test.js.map +1 -1
- package/dist/cli/__tests__/ralph-prd-smoke.test.js +7 -0
- package/dist/cli/__tests__/ralph-prd-smoke.test.js.map +1 -1
- package/dist/cli/__tests__/setup-install-mode.test.js +57 -21
- package/dist/cli/__tests__/setup-install-mode.test.js.map +1 -1
- package/dist/cli/__tests__/setup-refresh.test.js +27 -8
- package/dist/cli/__tests__/setup-refresh.test.js.map +1 -1
- package/dist/cli/__tests__/setup-scope.test.js +18 -9
- package/dist/cli/__tests__/setup-scope.test.js.map +1 -1
- package/dist/cli/__tests__/setup-skill-validation.test.js +11 -11
- package/dist/cli/__tests__/setup-skill-validation.test.js.map +1 -1
- package/dist/cli/__tests__/setup-skills-overwrite.test.js +12 -12
- package/dist/cli/__tests__/setup-skills-overwrite.test.js.map +1 -1
- package/dist/cli/__tests__/team.test.js +187 -0
- package/dist/cli/__tests__/team.test.js.map +1 -1
- package/dist/cli/__tests__/ultragoal.test.d.ts +2 -0
- package/dist/cli/__tests__/ultragoal.test.d.ts.map +1 -0
- package/dist/cli/__tests__/ultragoal.test.js +106 -0
- package/dist/cli/__tests__/ultragoal.test.js.map +1 -0
- package/dist/cli/__tests__/uninstall.test.js +11 -0
- package/dist/cli/__tests__/uninstall.test.js.map +1 -1
- package/dist/cli/autoresearch-goal.d.ts +3 -0
- package/dist/cli/autoresearch-goal.d.ts.map +1 -0
- package/dist/cli/autoresearch-goal.js +175 -0
- package/dist/cli/autoresearch-goal.js.map +1 -0
- package/dist/cli/cleanup.d.ts +3 -1
- package/dist/cli/cleanup.d.ts.map +1 -1
- package/dist/cli/cleanup.js +42 -2
- package/dist/cli/cleanup.js.map +1 -1
- package/dist/cli/doctor.d.ts.map +1 -1
- package/dist/cli/doctor.js +49 -0
- package/dist/cli/doctor.js.map +1 -1
- package/dist/cli/explore.d.ts.map +1 -1
- package/dist/cli/explore.js +10 -2
- package/dist/cli/explore.js.map +1 -1
- package/dist/cli/index.d.ts +6 -2
- package/dist/cli/index.d.ts.map +1 -1
- package/dist/cli/index.js +145 -18
- package/dist/cli/index.js.map +1 -1
- package/dist/cli/native-assets.js +1 -1
- package/dist/cli/native-assets.js.map +1 -1
- package/dist/cli/performance-goal.d.ts +3 -0
- package/dist/cli/performance-goal.d.ts.map +1 -0
- package/dist/cli/performance-goal.js +186 -0
- package/dist/cli/performance-goal.js.map +1 -0
- package/dist/cli/ralph.d.ts.map +1 -1
- package/dist/cli/ralph.js +8 -0
- package/dist/cli/ralph.js.map +1 -1
- package/dist/cli/setup.d.ts.map +1 -1
- package/dist/cli/setup.js +13 -6
- package/dist/cli/setup.js.map +1 -1
- package/dist/cli/team.d.ts +2 -0
- package/dist/cli/team.d.ts.map +1 -1
- package/dist/cli/team.js +72 -17
- package/dist/cli/team.js.map +1 -1
- package/dist/cli/tmux-hook.d.ts.map +1 -1
- package/dist/cli/tmux-hook.js +2 -1
- package/dist/cli/tmux-hook.js.map +1 -1
- package/dist/cli/ultragoal.d.ts +3 -0
- package/dist/cli/ultragoal.d.ts.map +1 -0
- package/dist/cli/ultragoal.js +191 -0
- package/dist/cli/ultragoal.js.map +1 -0
- package/dist/cli/uninstall.d.ts.map +1 -1
- package/dist/cli/uninstall.js +4 -2
- package/dist/cli/uninstall.js.map +1 -1
- package/dist/config/__tests__/generator-idempotent.test.js +12 -1
- package/dist/config/__tests__/generator-idempotent.test.js.map +1 -1
- package/dist/config/__tests__/generator-notify.test.js +5 -0
- package/dist/config/__tests__/generator-notify.test.js.map +1 -1
- package/dist/config/commit-lore-guard.d.ts +3 -0
- package/dist/config/commit-lore-guard.d.ts.map +1 -0
- package/dist/config/commit-lore-guard.js +9 -0
- package/dist/config/commit-lore-guard.js.map +1 -0
- package/dist/config/generator.d.ts +3 -2
- package/dist/config/generator.d.ts.map +1 -1
- package/dist/config/generator.js +52 -8
- package/dist/config/generator.js.map +1 -1
- package/dist/config/omx-first-party-mcp.d.ts +1 -0
- package/dist/config/omx-first-party-mcp.d.ts.map +1 -1
- package/dist/config/omx-first-party-mcp.js +4 -1
- package/dist/config/omx-first-party-mcp.js.map +1 -1
- package/dist/goal-workflows/__tests__/artifacts.test.d.ts +2 -0
- package/dist/goal-workflows/__tests__/artifacts.test.d.ts.map +1 -0
- package/dist/goal-workflows/__tests__/artifacts.test.js +96 -0
- package/dist/goal-workflows/__tests__/artifacts.test.js.map +1 -0
- package/dist/goal-workflows/__tests__/codex-goal-snapshot.test.d.ts +2 -0
- package/dist/goal-workflows/__tests__/codex-goal-snapshot.test.d.ts.map +1 -0
- package/dist/goal-workflows/__tests__/codex-goal-snapshot.test.js +54 -0
- package/dist/goal-workflows/__tests__/codex-goal-snapshot.test.js.map +1 -0
- package/dist/goal-workflows/artifacts.d.ts +62 -0
- package/dist/goal-workflows/artifacts.d.ts.map +1 -0
- package/dist/goal-workflows/artifacts.js +132 -0
- package/dist/goal-workflows/artifacts.js.map +1 -0
- package/dist/goal-workflows/codex-goal-snapshot.d.ts +28 -0
- package/dist/goal-workflows/codex-goal-snapshot.d.ts.map +1 -0
- package/dist/goal-workflows/codex-goal-snapshot.js +110 -0
- package/dist/goal-workflows/codex-goal-snapshot.js.map +1 -0
- package/dist/goal-workflows/handoff.d.ts +10 -0
- package/dist/goal-workflows/handoff.d.ts.map +1 -0
- package/dist/goal-workflows/handoff.js +31 -0
- package/dist/goal-workflows/handoff.js.map +1 -0
- package/dist/goal-workflows/validation.d.ts +13 -0
- package/dist/goal-workflows/validation.d.ts.map +1 -0
- package/dist/goal-workflows/validation.js +36 -0
- package/dist/goal-workflows/validation.js.map +1 -0
- package/dist/hooks/__tests__/anti-slop-workflow.test.js +3 -3
- package/dist/hooks/__tests__/anti-slop-workflow.test.js.map +1 -1
- package/dist/hooks/__tests__/keyword-detector.test.js +45 -32
- package/dist/hooks/__tests__/keyword-detector.test.js.map +1 -1
- package/dist/hooks/__tests__/notify-fallback-watcher.test.js +3 -3
- package/dist/hooks/__tests__/notify-fallback-watcher.test.js.map +1 -1
- package/dist/hooks/__tests__/notify-hook-team-dispatch.test.js +2 -1
- package/dist/hooks/__tests__/notify-hook-team-dispatch.test.js.map +1 -1
- package/dist/hooks/__tests__/notify-hook-team-leader-nudge.test.js +17 -24
- package/dist/hooks/__tests__/notify-hook-team-leader-nudge.test.js.map +1 -1
- package/dist/hooks/__tests__/prompt-guidance-wave-two.test.js +3 -3
- package/dist/hooks/__tests__/prompt-guidance-wave-two.test.js.map +1 -1
- package/dist/hooks/__tests__/task-size-detector.test.js +1 -1
- package/dist/hooks/__tests__/task-size-detector.test.js.map +1 -1
- package/dist/hooks/__tests__/visual-ralph-skill.test.js +3 -3
- package/dist/hooks/__tests__/visual-ralph-skill.test.js.map +1 -1
- package/dist/hooks/__tests__/visual-verdict-loop.test.js +7 -11
- package/dist/hooks/__tests__/visual-verdict-loop.test.js.map +1 -1
- package/dist/hooks/agents-overlay.d.ts.map +1 -1
- package/dist/hooks/agents-overlay.js +2 -2
- package/dist/hooks/agents-overlay.js.map +1 -1
- package/dist/hooks/keyword-detector.d.ts.map +1 -1
- package/dist/hooks/keyword-detector.js +12 -13
- package/dist/hooks/keyword-detector.js.map +1 -1
- package/dist/hooks/keyword-registry.d.ts.map +1 -1
- package/dist/hooks/keyword-registry.js +2 -10
- package/dist/hooks/keyword-registry.js.map +1 -1
- package/dist/hooks/prompt-guidance-contract.d.ts.map +1 -1
- package/dist/hooks/prompt-guidance-contract.js +0 -4
- package/dist/hooks/prompt-guidance-contract.js.map +1 -1
- package/dist/hooks/session.js +2 -2
- package/dist/hooks/session.js.map +1 -1
- package/dist/hooks/task-size-detector.d.ts.map +1 -1
- package/dist/hooks/task-size-detector.js +1 -0
- package/dist/hooks/task-size-detector.js.map +1 -1
- package/dist/hud/__tests__/reconcile.test.js +29 -7
- package/dist/hud/__tests__/reconcile.test.js.map +1 -1
- package/dist/hud/reconcile.d.ts +2 -1
- package/dist/hud/reconcile.d.ts.map +1 -1
- package/dist/hud/reconcile.js +12 -0
- package/dist/hud/reconcile.js.map +1 -1
- package/dist/mcp/__tests__/bootstrap.test.js +15 -2
- package/dist/mcp/__tests__/bootstrap.test.js.map +1 -1
- package/dist/mcp/__tests__/state-paths.test.js +54 -0
- package/dist/mcp/__tests__/state-paths.test.js.map +1 -1
- package/dist/mcp/__tests__/state-server.test.js +36 -0
- package/dist/mcp/__tests__/state-server.test.js.map +1 -1
- package/dist/mcp/bootstrap.d.ts +1 -1
- package/dist/mcp/bootstrap.d.ts.map +1 -1
- package/dist/mcp/bootstrap.js +9 -7
- package/dist/mcp/bootstrap.js.map +1 -1
- package/dist/mcp/state-paths.d.ts +17 -0
- package/dist/mcp/state-paths.d.ts.map +1 -1
- package/dist/mcp/state-paths.js +36 -2
- package/dist/mcp/state-paths.js.map +1 -1
- package/dist/modes/__tests__/base-session-scope.test.js +26 -0
- package/dist/modes/__tests__/base-session-scope.test.js.map +1 -1
- package/dist/modes/base.d.ts +1 -0
- package/dist/modes/base.d.ts.map +1 -1
- package/dist/modes/base.js +35 -5
- package/dist/modes/base.js.map +1 -1
- package/dist/notifications/__tests__/http-client.test.d.ts +2 -0
- package/dist/notifications/__tests__/http-client.test.d.ts.map +1 -0
- package/dist/notifications/__tests__/http-client.test.js +90 -0
- package/dist/notifications/__tests__/http-client.test.js.map +1 -0
- package/dist/notifications/__tests__/notifier.test.js +22 -60
- package/dist/notifications/__tests__/notifier.test.js.map +1 -1
- package/dist/notifications/dispatcher.d.ts.map +1 -1
- package/dist/notifications/dispatcher.js +35 -60
- package/dist/notifications/dispatcher.js.map +1 -1
- package/dist/notifications/http-client.d.ts +22 -0
- package/dist/notifications/http-client.d.ts.map +1 -0
- package/dist/notifications/http-client.js +298 -0
- package/dist/notifications/http-client.js.map +1 -0
- package/dist/notifications/notifier.d.ts +3 -2
- package/dist/notifications/notifier.d.ts.map +1 -1
- package/dist/notifications/notifier.js +17 -22
- package/dist/notifications/notifier.js.map +1 -1
- package/dist/openclaw/__tests__/dispatcher.test.js +62 -1
- package/dist/openclaw/__tests__/dispatcher.test.js.map +1 -1
- package/dist/openclaw/dispatcher.d.ts.map +1 -1
- package/dist/openclaw/dispatcher.js +3 -2
- package/dist/openclaw/dispatcher.js.map +1 -1
- package/dist/performance-goal/artifacts.d.ts +76 -0
- package/dist/performance-goal/artifacts.d.ts.map +1 -0
- package/dist/performance-goal/artifacts.js +221 -0
- package/dist/performance-goal/artifacts.js.map +1 -0
- package/dist/pipeline/__tests__/stages.test.js +30 -5
- package/dist/pipeline/__tests__/stages.test.js.map +1 -1
- package/dist/pipeline/stages/team-exec.d.ts.map +1 -1
- package/dist/pipeline/stages/team-exec.js +2 -19
- package/dist/pipeline/stages/team-exec.js.map +1 -1
- package/dist/planning/__tests__/artifacts.test.js +16 -1
- package/dist/planning/__tests__/artifacts.test.js.map +1 -1
- package/dist/planning/artifacts.d.ts +1 -0
- package/dist/planning/artifacts.d.ts.map +1 -1
- package/dist/planning/artifacts.js +9 -12
- package/dist/planning/artifacts.js.map +1 -1
- package/dist/ralplan/__tests__/runtime.test.js +2 -0
- package/dist/ralplan/__tests__/runtime.test.js.map +1 -1
- package/dist/ralplan/runtime.d.ts.map +1 -1
- package/dist/ralplan/runtime.js +6 -0
- package/dist/ralplan/runtime.js.map +1 -1
- package/dist/scripts/__tests__/codex-native-hook.test.js +1516 -205
- package/dist/scripts/__tests__/codex-native-hook.test.js.map +1 -1
- package/dist/scripts/__tests__/hook-derived-watcher.test.js +33 -1
- package/dist/scripts/__tests__/hook-derived-watcher.test.js.map +1 -1
- package/dist/scripts/__tests__/run-test-files.test.js +36 -0
- package/dist/scripts/__tests__/run-test-files.test.js.map +1 -1
- package/dist/scripts/codex-native-hook.d.ts.map +1 -1
- package/dist/scripts/codex-native-hook.js +497 -51
- package/dist/scripts/codex-native-hook.js.map +1 -1
- package/dist/scripts/codex-native-pre-post.d.ts +7 -0
- package/dist/scripts/codex-native-pre-post.d.ts.map +1 -1
- package/dist/scripts/codex-native-pre-post.js +222 -19
- package/dist/scripts/codex-native-pre-post.js.map +1 -1
- package/dist/scripts/hook-derived-watcher.js +2 -1
- package/dist/scripts/hook-derived-watcher.js.map +1 -1
- package/dist/scripts/notify-fallback-watcher.js +2 -1
- package/dist/scripts/notify-fallback-watcher.js.map +1 -1
- package/dist/scripts/notify-hook/orchestration-intent.d.ts +1 -2
- package/dist/scripts/notify-hook/orchestration-intent.d.ts.map +1 -1
- package/dist/scripts/notify-hook/orchestration-intent.js +2 -3
- package/dist/scripts/notify-hook/orchestration-intent.js.map +1 -1
- package/dist/scripts/notify-hook/team-leader-nudge.d.ts +0 -2
- package/dist/scripts/notify-hook/team-leader-nudge.d.ts.map +1 -1
- package/dist/scripts/notify-hook/team-leader-nudge.js +8 -60
- package/dist/scripts/notify-hook/team-leader-nudge.js.map +1 -1
- package/dist/scripts/notify-hook/team-worker-stop.d.ts +15 -0
- package/dist/scripts/notify-hook/team-worker-stop.d.ts.map +1 -0
- package/dist/scripts/notify-hook/team-worker-stop.js +224 -0
- package/dist/scripts/notify-hook/team-worker-stop.js.map +1 -0
- package/dist/scripts/notify-hook/team-worker.d.ts.map +1 -1
- package/dist/scripts/notify-hook/team-worker.js +26 -18
- package/dist/scripts/notify-hook/team-worker.js.map +1 -1
- package/dist/scripts/run-test-files.js +17 -1
- package/dist/scripts/run-test-files.js.map +1 -1
- package/dist/scripts/sync-plugin-mirror.js +2 -2
- package/dist/scripts/sync-plugin-mirror.js.map +1 -1
- package/dist/state/__tests__/operations.test.js +26 -0
- package/dist/state/__tests__/operations.test.js.map +1 -1
- package/dist/state/__tests__/skill-active.test.js +35 -0
- package/dist/state/__tests__/skill-active.test.js.map +1 -1
- package/dist/state/operations.d.ts +3 -1
- package/dist/state/operations.d.ts.map +1 -1
- package/dist/state/operations.js +8 -4
- package/dist/state/operations.js.map +1 -1
- package/dist/state/skill-active.d.ts +1 -0
- package/dist/state/skill-active.d.ts.map +1 -1
- package/dist/state/skill-active.js +54 -13
- package/dist/state/skill-active.js.map +1 -1
- package/dist/team/__tests__/api-interop.test.js +59 -0
- package/dist/team/__tests__/api-interop.test.js.map +1 -1
- package/dist/team/__tests__/approved-execution.test.d.ts +2 -0
- package/dist/team/__tests__/approved-execution.test.d.ts.map +1 -0
- package/dist/team/__tests__/approved-execution.test.js +124 -0
- package/dist/team/__tests__/approved-execution.test.js.map +1 -0
- package/dist/team/__tests__/delivery-e2e-smoke.test.js +2 -4
- package/dist/team/__tests__/delivery-e2e-smoke.test.js.map +1 -1
- package/dist/team/__tests__/delivery-log.test.d.ts +2 -0
- package/dist/team/__tests__/delivery-log.test.d.ts.map +1 -0
- package/dist/team/__tests__/delivery-log.test.js +44 -0
- package/dist/team/__tests__/delivery-log.test.js.map +1 -0
- package/dist/team/__tests__/role-router.test.js +4 -4
- package/dist/team/__tests__/role-router.test.js.map +1 -1
- package/dist/team/__tests__/runtime-boxed-state.test.d.ts +2 -0
- package/dist/team/__tests__/runtime-boxed-state.test.d.ts.map +1 -0
- package/dist/team/__tests__/runtime-boxed-state.test.js +39 -0
- package/dist/team/__tests__/runtime-boxed-state.test.js.map +1 -0
- package/dist/team/__tests__/runtime.test.js +118 -6
- package/dist/team/__tests__/runtime.test.js.map +1 -1
- package/dist/team/__tests__/state-root.test.js +13 -0
- package/dist/team/__tests__/state-root.test.js.map +1 -1
- package/dist/team/__tests__/tmux-session.test.js +3 -0
- package/dist/team/__tests__/tmux-session.test.js.map +1 -1
- package/dist/team/__tests__/worker-bootstrap.test.js +50 -0
- package/dist/team/__tests__/worker-bootstrap.test.js.map +1 -1
- package/dist/team/api-interop.d.ts.map +1 -1
- package/dist/team/api-interop.js +4 -3
- package/dist/team/api-interop.js.map +1 -1
- package/dist/team/approved-execution.d.ts +37 -0
- package/dist/team/approved-execution.d.ts.map +1 -0
- package/dist/team/approved-execution.js +136 -0
- package/dist/team/approved-execution.js.map +1 -0
- package/dist/team/delivery-log.d.ts.map +1 -1
- package/dist/team/delivery-log.js +2 -1
- package/dist/team/delivery-log.js.map +1 -1
- package/dist/team/followup-planner.js +2 -2
- package/dist/team/followup-planner.js.map +1 -1
- package/dist/team/goal-workflow.d.ts +20 -0
- package/dist/team/goal-workflow.d.ts.map +1 -0
- package/dist/team/goal-workflow.js +57 -0
- package/dist/team/goal-workflow.js.map +1 -0
- package/dist/team/orchestrator.js +2 -2
- package/dist/team/orchestrator.js.map +1 -1
- package/dist/team/role-router.js +5 -5
- package/dist/team/role-router.js.map +1 -1
- package/dist/team/runtime.d.ts +6 -0
- package/dist/team/runtime.d.ts.map +1 -1
- package/dist/team/runtime.js +46 -6
- package/dist/team/runtime.js.map +1 -1
- package/dist/team/scaling.d.ts.map +1 -1
- package/dist/team/scaling.js +2 -0
- package/dist/team/scaling.js.map +1 -1
- package/dist/team/tmux-session.d.ts.map +1 -1
- package/dist/team/tmux-session.js +4 -2
- package/dist/team/tmux-session.js.map +1 -1
- package/dist/team/worker-bootstrap.d.ts +2 -0
- package/dist/team/worker-bootstrap.d.ts.map +1 -1
- package/dist/team/worker-bootstrap.js +19 -2
- package/dist/team/worker-bootstrap.js.map +1 -1
- package/dist/ultragoal/__tests__/artifacts.test.d.ts +2 -0
- package/dist/ultragoal/__tests__/artifacts.test.d.ts.map +1 -0
- package/dist/ultragoal/__tests__/artifacts.test.js +93 -0
- package/dist/ultragoal/__tests__/artifacts.test.js.map +1 -0
- package/dist/ultragoal/artifacts.d.ts +89 -0
- package/dist/ultragoal/artifacts.d.ts.map +1 -0
- package/dist/ultragoal/artifacts.js +233 -0
- package/dist/ultragoal/artifacts.js.map +1 -0
- package/dist/utils/__tests__/agents-model-table.test.js +3 -1
- package/dist/utils/__tests__/agents-model-table.test.js.map +1 -1
- package/dist/utils/__tests__/paths.test.js +31 -1
- package/dist/utils/__tests__/paths.test.js.map +1 -1
- package/dist/utils/agents-model-table.d.ts.map +1 -1
- package/dist/utils/agents-model-table.js +12 -1
- package/dist/utils/agents-model-table.js.map +1 -1
- package/dist/utils/paths.d.ts +2 -0
- package/dist/utils/paths.d.ts.map +1 -1
- package/dist/utils/paths.js +23 -7
- package/dist/utils/paths.js.map +1 -1
- package/dist/verification/__tests__/ci-rust-gates.test.js +30 -19
- package/dist/verification/__tests__/ci-rust-gates.test.js.map +1 -1
- package/package.json +5 -5
- package/plugins/oh-my-codex/.codex-plugin/plugin.json +1 -1
- package/plugins/oh-my-codex/skills/ask/SKILL.md +58 -0
- package/plugins/oh-my-codex/skills/autoresearch-goal/SKILL.md +36 -0
- package/plugins/oh-my-codex/skills/omx-setup/SKILL.md +2 -2
- package/plugins/oh-my-codex/skills/performance-goal/SKILL.md +65 -0
- package/plugins/oh-my-codex/skills/plan/SKILL.md +1 -1
- package/plugins/oh-my-codex/skills/ralph/SKILL.md +22 -3
- package/plugins/oh-my-codex/skills/team/SKILL.md +6 -2
- package/plugins/oh-my-codex/skills/ultragoal/SKILL.md +49 -0
- package/plugins/oh-my-codex/skills/visual-ralph/SKILL.md +9 -9
- package/prompts/api-reviewer.md +1 -1
- package/prompts/code-reviewer.md +2 -0
- package/prompts/performance-reviewer.md +1 -1
- package/prompts/quality-reviewer.md +1 -1
- package/prompts/quality-strategist.md +2 -2
- package/prompts/style-reviewer.md +1 -1
- package/prompts/test-engineer.md +1 -1
- package/skills/ask/SKILL.md +58 -0
- package/skills/ask-claude/SKILL.md +3 -54
- package/skills/ask-gemini/SKILL.md +3 -54
- package/skills/autoresearch-goal/SKILL.md +36 -0
- package/skills/build-fix/SKILL.md +4 -139
- package/skills/deepsearch/SKILL.md +4 -32
- package/skills/ecomode/SKILL.md +4 -108
- package/skills/help/SKILL.md +4 -196
- package/skills/note/SKILL.md +4 -56
- package/skills/omx-setup/SKILL.md +2 -2
- package/skills/performance-goal/SKILL.md +65 -0
- package/skills/plan/SKILL.md +1 -1
- package/skills/ralph/SKILL.md +22 -3
- package/skills/ralph-init/SKILL.md +4 -40
- package/skills/review/SKILL.md +4 -32
- package/skills/security-review/SKILL.md +4 -294
- package/skills/swarm/SKILL.md +4 -19
- package/skills/tdd/SKILL.md +4 -100
- package/skills/team/SKILL.md +6 -2
- package/skills/trace/SKILL.md +4 -27
- package/skills/ultragoal/SKILL.md +49 -0
- package/skills/visual-ralph/SKILL.md +9 -9
- package/skills/visual-verdict/SKILL.md +4 -70
- package/skills/web-clone/SKILL.md +4 -18
- package/src/scripts/__tests__/codex-native-hook.test.ts +1654 -157
- package/src/scripts/__tests__/hook-derived-watcher.test.ts +45 -1
- package/src/scripts/__tests__/run-test-files.test.ts +46 -0
- package/src/scripts/codex-native-hook.ts +592 -52
- package/src/scripts/codex-native-pre-post.ts +252 -20
- package/src/scripts/hook-derived-watcher.ts +2 -1
- package/src/scripts/notify-fallback-watcher.ts +2 -1
- package/src/scripts/notify-hook/orchestration-intent.ts +1 -3
- package/src/scripts/notify-hook/team-leader-nudge.ts +7 -63
- package/src/scripts/notify-hook/team-worker-stop.ts +246 -0
- package/src/scripts/notify-hook/team-worker.ts +23 -14
- package/src/scripts/run-test-files.ts +20 -1
- package/src/scripts/sync-plugin-mirror.ts +2 -2
- package/templates/catalog-manifest.json +45 -27
- package/plugins/oh-my-codex/skills/ask-claude/SKILL.md +0 -61
- package/plugins/oh-my-codex/skills/ask-gemini/SKILL.md +0 -61
- package/plugins/oh-my-codex/skills/help/SKILL.md +0 -202
- package/plugins/oh-my-codex/skills/note/SKILL.md +0 -62
- package/plugins/oh-my-codex/skills/security-review/SKILL.md +0 -300
- package/plugins/oh-my-codex/skills/trace/SKILL.md +0 -33
- package/plugins/oh-my-codex/skills/visual-verdict/SKILL.md +0 -76
package/dist/cli/index.js
CHANGED
|
@@ -6,7 +6,7 @@ import { execFileSync, spawn } from "child_process";
|
|
|
6
6
|
import { basename, dirname, join } from "path";
|
|
7
7
|
import { existsSync, mkdirSync, readFileSync, rmSync, statSync, writeFileSync } from "fs";
|
|
8
8
|
import { copyFile, cp, lstat, mkdir, readdir, rm, symlink } from "fs/promises";
|
|
9
|
-
import { constants as osConstants } from "os";
|
|
9
|
+
import { constants as osConstants, homedir } from "os";
|
|
10
10
|
import { setup, SETUP_SCOPES } from "./setup.js";
|
|
11
11
|
import { uninstall } from "./uninstall.js";
|
|
12
12
|
import { version } from "./version.js";
|
|
@@ -16,6 +16,8 @@ import { hudCommand } from "../hud/index.js";
|
|
|
16
16
|
import { sidecarCommand } from "../sidecar/index.js";
|
|
17
17
|
import { teamCommand } from "./team.js";
|
|
18
18
|
import { ralphCommand } from "./ralph.js";
|
|
19
|
+
import { ultragoalCommand } from "./ultragoal.js";
|
|
20
|
+
import { performanceGoalCommand } from "./performance-goal.js";
|
|
19
21
|
import { askCommand } from "./ask.js";
|
|
20
22
|
import { questionCommand } from "./question.js";
|
|
21
23
|
import { stateCommand } from "./state.js";
|
|
@@ -26,6 +28,7 @@ import { agentsInitCommand } from "./agents-init.js";
|
|
|
26
28
|
import { agentsCommand } from "./agents.js";
|
|
27
29
|
import { sessionCommand } from "./session-search.js";
|
|
28
30
|
import { autoresearchCommand } from "./autoresearch.js";
|
|
31
|
+
import { autoresearchGoalCommand } from "./autoresearch-goal.js";
|
|
29
32
|
import { mcpParityCommand } from "./mcp-parity.js";
|
|
30
33
|
import { mcpServeCommand } from "./mcp-serve.js";
|
|
31
34
|
import { adaptCommand } from "./adapt.js";
|
|
@@ -42,9 +45,10 @@ import { generateOverlay, removeSessionModelInstructionsFile, resolveSessionOrch
|
|
|
42
45
|
import { readSessionState, writeSessionStart, writeSessionEnd, resetSessionMetrics, } from "../hooks/session.js";
|
|
43
46
|
import { buildClientAttachedReconcileHookName, buildReconcileHudResizeArgs, buildRegisterClientAttachedReconcileArgs, buildRegisterResizeHookArgs, buildResizeHookName, buildResizeHookTarget, buildScheduleDelayedHudResizeArgs, buildUnregisterClientAttachedReconcileArgs, buildUnregisterResizeHookArgs, enableMouseScrolling, isMsysOrGitBash, isNativeWindows, isTmuxAvailable, mitigateCopyModeUnderlineArtifacts, } from "../team/tmux-session.js";
|
|
44
47
|
import { getPackageRoot } from "../utils/package.js";
|
|
45
|
-
import { codexConfigPath, rememberOmxLaunchContext, resolveOmxEntryPath } from "../utils/paths.js";
|
|
48
|
+
import { codexConfigPath, omxRoot, rememberOmxLaunchContext, resolveOmxEntryPath } from "../utils/paths.js";
|
|
46
49
|
import { cleanCodexModelAvailabilityNuxIfNeeded, repairConfigIfNeeded } from "../config/generator.js";
|
|
47
50
|
import { HUD_TMUX_HEIGHT_LINES } from "../hud/constants.js";
|
|
51
|
+
import { OMX_TMUX_HUD_OWNER_ENV } from "../hud/reconcile.js";
|
|
48
52
|
import { createHudWatchPane as createSharedHudWatchPane, killTmuxPane as killSharedTmuxPane, listCurrentWindowHudPaneIds, parsePaneIdFromTmuxOutput, } from "../hud/tmux.js";
|
|
49
53
|
export { parseTmuxPaneSnapshot, isHudWatchPane, findHudWatchPaneIds } from "../hud/tmux.js";
|
|
50
54
|
rememberOmxLaunchContext();
|
|
@@ -97,6 +101,11 @@ Usage:
|
|
|
97
101
|
Alias for agents-init (lightweight AGENTS bootstrap only)
|
|
98
102
|
omx team Spawn parallel worker panes in tmux and bootstrap inbox/task state
|
|
99
103
|
omx ralph Launch Codex with ralph persistence mode active
|
|
104
|
+
omx ultragoal Create, resume, and checkpoint durable multi-goal plans over Codex goal mode
|
|
105
|
+
omx performance-goal
|
|
106
|
+
Create, hand off, and gate evaluator-backed performance goals
|
|
107
|
+
omx autoresearch-goal
|
|
108
|
+
Create, hand off, and gate professor-critic research goals
|
|
100
109
|
omx autoresearch [DEPRECATED] Use $autoresearch; direct CLI launch removed
|
|
101
110
|
omx version Show version information
|
|
102
111
|
omx tmux-hook Manage tmux prompt injection workaround (init|status|validate|test)
|
|
@@ -214,6 +223,7 @@ const NESTED_HELP_COMMANDS = new Set([
|
|
|
214
223
|
"cleanup",
|
|
215
224
|
"adapt",
|
|
216
225
|
"autoresearch",
|
|
226
|
+
"autoresearch-goal",
|
|
217
227
|
"agents",
|
|
218
228
|
"agents-init",
|
|
219
229
|
"deepinit",
|
|
@@ -226,6 +236,8 @@ const NESTED_HELP_COMMANDS = new Set([
|
|
|
226
236
|
"wiki",
|
|
227
237
|
"mcp-serve",
|
|
228
238
|
"ralph",
|
|
239
|
+
"ultragoal",
|
|
240
|
+
"performance-goal",
|
|
229
241
|
"resume",
|
|
230
242
|
"session",
|
|
231
243
|
"sparkshell",
|
|
@@ -395,7 +407,7 @@ function resolveTmuxExecutableForLaunch() {
|
|
|
395
407
|
return resolveTmuxBinaryForPlatform() || "tmux";
|
|
396
408
|
}
|
|
397
409
|
export function runtimeCodexHomePath(cwd, sessionId) {
|
|
398
|
-
return join(cwd, "
|
|
410
|
+
return join(omxRoot(cwd), "runtime", "codex-home", sessionId);
|
|
399
411
|
}
|
|
400
412
|
async function linkOrCopyCodexHomeEntry(source, destination) {
|
|
401
413
|
const stat = await lstat(source);
|
|
@@ -512,6 +524,42 @@ function warnDetachedTmuxFallback(reason) {
|
|
|
512
524
|
const suffix = reason ? ` (${reason})` : "";
|
|
513
525
|
console.warn(`[omx] warning: tmux is installed but its server/socket is unusable${suffix}. Falling back to direct Codex launch.`);
|
|
514
526
|
}
|
|
527
|
+
const QUICK_ATTACH_NOOP_THRESHOLD_MS = 2_000;
|
|
528
|
+
function isWslWindowsTerminalEnvironment(env) {
|
|
529
|
+
return Boolean(env.WT_SESSION?.trim() &&
|
|
530
|
+
(env.WSL_INTEROP?.trim() ||
|
|
531
|
+
env.WSL_DISTRO_NAME?.trim() ||
|
|
532
|
+
env.WSLENV?.trim()));
|
|
533
|
+
}
|
|
534
|
+
function readDetachedSessionAttachedClientCount(sessionName) {
|
|
535
|
+
try {
|
|
536
|
+
const output = execTmuxFileSync(["display-message", "-p", "-t", sessionName, "#{session_attached}"], {
|
|
537
|
+
stdio: ["ignore", "pipe", "pipe"],
|
|
538
|
+
encoding: "utf-8",
|
|
539
|
+
}).trim();
|
|
540
|
+
const parsed = Number.parseInt(output, 10);
|
|
541
|
+
return Number.isFinite(parsed) ? parsed : null;
|
|
542
|
+
}
|
|
543
|
+
catch (err) {
|
|
544
|
+
logCliOperationFailure(err);
|
|
545
|
+
return null;
|
|
546
|
+
}
|
|
547
|
+
}
|
|
548
|
+
function assertDetachedAttachDidNotNoop(sessionName, elapsedMs, env) {
|
|
549
|
+
if (!isWslWindowsTerminalEnvironment(env))
|
|
550
|
+
return;
|
|
551
|
+
if (elapsedMs >= QUICK_ATTACH_NOOP_THRESHOLD_MS)
|
|
552
|
+
return;
|
|
553
|
+
const attachedClients = readDetachedSessionAttachedClientCount(sessionName);
|
|
554
|
+
if (attachedClients === null || attachedClients > 0)
|
|
555
|
+
return;
|
|
556
|
+
throw new Error([
|
|
557
|
+
"tmux attach-session returned immediately without attaching a client",
|
|
558
|
+
`(session=${sessionName}).`,
|
|
559
|
+
"This can happen on WSL2 under Windows Terminal.",
|
|
560
|
+
"Falling back to direct Codex launch.",
|
|
561
|
+
].join(" "));
|
|
562
|
+
}
|
|
515
563
|
function resolveTmuxAwareLaunchPolicy(explicitLaunchPolicy, nativeWindows) {
|
|
516
564
|
const launchPolicy = resolveCodexLaunchPolicy(process.env, process.platform, undefined, nativeWindows, undefined, undefined, explicitLaunchPolicy);
|
|
517
565
|
if (launchPolicy !== "detached-tmux") {
|
|
@@ -606,6 +654,51 @@ export function buildHudPaneCleanupTargets(existingPaneIds, createdPaneId, leade
|
|
|
606
654
|
}
|
|
607
655
|
return [...targets];
|
|
608
656
|
}
|
|
657
|
+
export function resolveOmxRootForLaunch(cwd, env = process.env) {
|
|
658
|
+
const raw = env.OMX_ROOT || env.OMX_STATE_ROOT;
|
|
659
|
+
if (typeof raw !== "string" || raw.trim() === "")
|
|
660
|
+
return undefined;
|
|
661
|
+
return raw.startsWith("/") ? raw : join(cwd, raw);
|
|
662
|
+
}
|
|
663
|
+
export function shouldAutoIsolateMadmaxLaunch(command, launchArgs, env = process.env) {
|
|
664
|
+
if (command !== "launch" && command !== "exec")
|
|
665
|
+
return false;
|
|
666
|
+
if (env.OMX_NO_BOX === "1" || env.OMXBOX_ACTIVE === "1")
|
|
667
|
+
return false;
|
|
668
|
+
if (env.OMX_ROOT || env.OMX_STATE_ROOT)
|
|
669
|
+
return false;
|
|
670
|
+
return launchArgs.some((arg) => arg === MADMAX_FLAG || arg === MADMAX_SPARK_FLAG);
|
|
671
|
+
}
|
|
672
|
+
function sanitizeRunIdSegment(value) {
|
|
673
|
+
return value.replace(/[^a-zA-Z0-9._-]/g, "-").replace(/-+/g, "-").replace(/^-|-$/g, "");
|
|
674
|
+
}
|
|
675
|
+
export function createMadmaxIsolatedRoot(sourceCwd, argv, env = process.env) {
|
|
676
|
+
const runsRoot = env.OMX_RUNS_DIR || join(homedir(), ".omx-runs");
|
|
677
|
+
mkdirSync(runsRoot, { recursive: true });
|
|
678
|
+
const stamp = new Date().toISOString().replace(/[-:TZ.]/g, "").slice(0, 14);
|
|
679
|
+
const suffix = Math.random().toString(16).slice(2, 6);
|
|
680
|
+
const runDir = join(runsRoot, sanitizeRunIdSegment(`run-${stamp}-${suffix}`));
|
|
681
|
+
mkdirSync(runDir, { recursive: false });
|
|
682
|
+
const metadata = {
|
|
683
|
+
launcher: "omx --madmax",
|
|
684
|
+
created_at: new Date().toISOString(),
|
|
685
|
+
cwd: runDir,
|
|
686
|
+
source_cwd: sourceCwd,
|
|
687
|
+
argv,
|
|
688
|
+
};
|
|
689
|
+
writeFileSync(join(runDir, ".omxbox-run.json"), `${JSON.stringify(metadata, null, 2)}\n`);
|
|
690
|
+
writeFileSync(join(runsRoot, "registry.jsonl"), `${JSON.stringify(metadata)}\n`, { flag: "a" });
|
|
691
|
+
return runDir;
|
|
692
|
+
}
|
|
693
|
+
function activateMadmaxIsolationIfNeeded(command, launchArgs, cwd, env = process.env) {
|
|
694
|
+
if (!shouldAutoIsolateMadmaxLaunch(command, launchArgs, env))
|
|
695
|
+
return;
|
|
696
|
+
const runDir = createMadmaxIsolatedRoot(cwd, launchArgs, env);
|
|
697
|
+
env.OMX_ROOT = runDir;
|
|
698
|
+
env.OMXBOX_ACTIVE = "1";
|
|
699
|
+
env.OMX_SOURCE_CWD = cwd;
|
|
700
|
+
process.stderr.write(`[omx] madmax isolated state: ${runDir} (source: ${cwd})\n`);
|
|
701
|
+
}
|
|
609
702
|
export async function main(args) {
|
|
610
703
|
const knownCommands = new Set([
|
|
611
704
|
"launch",
|
|
@@ -622,10 +715,13 @@ export async function main(args) {
|
|
|
622
715
|
"ask",
|
|
623
716
|
"question",
|
|
624
717
|
"autoresearch",
|
|
718
|
+
"autoresearch-goal",
|
|
625
719
|
"explore",
|
|
626
720
|
"sparkshell",
|
|
627
721
|
"team",
|
|
628
722
|
"ralph",
|
|
723
|
+
"ultragoal",
|
|
724
|
+
"performance-goal",
|
|
629
725
|
"session",
|
|
630
726
|
"resume",
|
|
631
727
|
"version",
|
|
@@ -655,6 +751,7 @@ export async function main(args) {
|
|
|
655
751
|
console.log(HELP);
|
|
656
752
|
return;
|
|
657
753
|
}
|
|
754
|
+
activateMadmaxIsolationIfNeeded(command, launchArgs, process.cwd(), process.env);
|
|
658
755
|
try {
|
|
659
756
|
switch (command) {
|
|
660
757
|
case "launch":
|
|
@@ -717,6 +814,9 @@ export async function main(args) {
|
|
|
717
814
|
case "autoresearch":
|
|
718
815
|
await autoresearchCommand(args.slice(1));
|
|
719
816
|
break;
|
|
817
|
+
case "autoresearch-goal":
|
|
818
|
+
await autoresearchGoalCommand(args.slice(1));
|
|
819
|
+
break;
|
|
720
820
|
case "explore":
|
|
721
821
|
await exploreCommand(args.slice(1));
|
|
722
822
|
break;
|
|
@@ -740,6 +840,12 @@ export async function main(args) {
|
|
|
740
840
|
case "ralph":
|
|
741
841
|
await ralphCommand(args.slice(1));
|
|
742
842
|
break;
|
|
843
|
+
case "ultragoal":
|
|
844
|
+
await ultragoalCommand(args.slice(1));
|
|
845
|
+
break;
|
|
846
|
+
case "performance-goal":
|
|
847
|
+
await performanceGoalCommand(args.slice(1));
|
|
848
|
+
break;
|
|
743
849
|
case "version":
|
|
744
850
|
version();
|
|
745
851
|
break;
|
|
@@ -1049,9 +1155,12 @@ export async function execWithOverlay(args) {
|
|
|
1049
1155
|
? serializeNotifyTempContract(notifyTempResult.contract)
|
|
1050
1156
|
: null;
|
|
1051
1157
|
const codexArgs = injectModelInstructionsBypassArgs(cwd, ["exec", ...normalizedArgs], process.env, sessionModelInstructionsPath(cwd, sessionId));
|
|
1052
|
-
const
|
|
1053
|
-
|
|
1054
|
-
|
|
1158
|
+
const omxRootOverride = resolveOmxRootForLaunch(cwd, process.env);
|
|
1159
|
+
const codexEnvBase = {
|
|
1160
|
+
...process.env,
|
|
1161
|
+
...(codexHomeOverride ? { CODEX_HOME: codexHomeOverride } : {}),
|
|
1162
|
+
...(omxRootOverride ? { OMX_ROOT: omxRootOverride } : {}),
|
|
1163
|
+
};
|
|
1055
1164
|
const codexEnv = notifyTempContractRaw
|
|
1056
1165
|
? {
|
|
1057
1166
|
...codexEnvBase,
|
|
@@ -1412,7 +1521,7 @@ function blockMs(ms) {
|
|
|
1412
1521
|
Atomics.wait(view, 0, 0, delay);
|
|
1413
1522
|
}
|
|
1414
1523
|
function tmuxExtendedKeysLeaseRoot(cwd) {
|
|
1415
|
-
return join(cwd, "
|
|
1524
|
+
return join(omxRoot(cwd), "state", TMUX_EXTENDED_KEYS_LEASE_DIR);
|
|
1416
1525
|
}
|
|
1417
1526
|
function resolveTmuxSocketPath(execFileSyncImpl = (file, tmuxArgs) => execFileSync(file, tmuxArgs, {
|
|
1418
1527
|
encoding: "utf-8",
|
|
@@ -1745,7 +1854,7 @@ export function withTmuxExtendedKeys(cwd, run, execFileSyncImpl = (file, tmuxArg
|
|
|
1745
1854
|
releaseTmuxExtendedKeysLease(cwd, leaseHandle, execFileSyncImpl);
|
|
1746
1855
|
}
|
|
1747
1856
|
}
|
|
1748
|
-
export function buildDetachedSessionBootstrapSteps(sessionName, cwd, codexCmd, hudCmd, workerLaunchArgs, codexHomeOverride, notifyTempContractRaw, nativeWindows = false, sessionId, projectLocalCodexHomeForCleanup, runtimeCodexHomeForCleanup) {
|
|
1857
|
+
export function buildDetachedSessionBootstrapSteps(sessionName, cwd, codexCmd, hudCmd, workerLaunchArgs, codexHomeOverride, notifyTempContractRaw, nativeWindows = false, sessionId, projectLocalCodexHomeForCleanup, runtimeCodexHomeForCleanup, omxRootOverride, env = process.env) {
|
|
1749
1858
|
const detachedLeaderCmd = nativeWindows
|
|
1750
1859
|
? "powershell.exe"
|
|
1751
1860
|
: buildDetachedSessionLeaderCommand(cwd, sessionName, codexCmd, sessionId, codexHomeOverride, projectLocalCodexHomeForCleanup, runtimeCodexHomeForCleanup);
|
|
@@ -1763,7 +1872,12 @@ export function buildDetachedSessionBootstrapSteps(sessionName, cwd, codexCmd, h
|
|
|
1763
1872
|
? ["-e", `${TEAM_WORKER_LAUNCH_ARGS_ENV}=${workerLaunchArgs}`]
|
|
1764
1873
|
: []),
|
|
1765
1874
|
...(sessionId ? ["-e", `OMX_SESSION_ID=${sessionId}`] : []),
|
|
1875
|
+
...(sessionId ? ["-e", `${OMX_TMUX_HUD_OWNER_ENV}=1`] : []),
|
|
1766
1876
|
...(codexHomeOverride ? ["-e", `CODEX_HOME=${codexHomeOverride}`] : []),
|
|
1877
|
+
...(omxRootOverride ? ["-e", `OMX_ROOT=${omxRootOverride}`] : []),
|
|
1878
|
+
...(env.OMX_STATE_ROOT ? ["-e", `OMX_STATE_ROOT=${env.OMX_STATE_ROOT}`] : []),
|
|
1879
|
+
...(env.OMXBOX_ACTIVE ? ["-e", `OMXBOX_ACTIVE=${env.OMXBOX_ACTIVE}`] : []),
|
|
1880
|
+
...(env.OMX_SOURCE_CWD ? ["-e", `OMX_SOURCE_CWD=${env.OMX_SOURCE_CWD}`] : []),
|
|
1767
1881
|
...(notifyTempContractRaw
|
|
1768
1882
|
? ["-e", `${OMX_NOTIFY_TEMP_CONTRACT_ENV}=${notifyTempContractRaw}`]
|
|
1769
1883
|
: []),
|
|
@@ -1890,6 +2004,7 @@ export function buildNotifyFallbackWatcherEnv(env = process.env, options = {}) {
|
|
|
1890
2004
|
return {
|
|
1891
2005
|
...nextEnv,
|
|
1892
2006
|
...(options.codexHomeOverride ? { CODEX_HOME: options.codexHomeOverride } : {}),
|
|
2007
|
+
...(options.omxRootOverride ? { OMX_ROOT: options.omxRootOverride } : {}),
|
|
1893
2008
|
...(options.sessionId ? { OMX_SESSION_ID: options.sessionId } : {}),
|
|
1894
2009
|
OMX_HUD_AUTHORITY: options.enableAuthority ? "1" : "0",
|
|
1895
2010
|
};
|
|
@@ -2206,13 +2321,20 @@ function runCodex(cwd, args, sessionId, workerDefaultModel, codexHomeOverride, n
|
|
|
2206
2321
|
}
|
|
2207
2322
|
const hudCmd = nativeWindows
|
|
2208
2323
|
? buildWindowsPromptCommand("node", [omxBin, "hud", "--watch"])
|
|
2209
|
-
: buildTmuxPaneCommand("env", [`OMX_SESSION_ID=${sessionId}`, "node", omxBin, "hud", "--watch"]);
|
|
2324
|
+
: buildTmuxPaneCommand("env", [`OMX_SESSION_ID=${sessionId}`, `${OMX_TMUX_HUD_OWNER_ENV}=1`, "node", omxBin, "hud", "--watch"]);
|
|
2210
2325
|
const inheritLeaderFlags = process.env[TEAM_INHERIT_LEADER_FLAGS_ENV] !== "0";
|
|
2211
2326
|
const workerLaunchArgs = resolveTeamWorkerLaunchArgsEnv(process.env[TEAM_WORKER_LAUNCH_ARGS_ENV], launchArgs, inheritLeaderFlags, workerDefaultModel);
|
|
2212
|
-
const
|
|
2213
|
-
|
|
2214
|
-
|
|
2215
|
-
|
|
2327
|
+
const omxRootOverride = resolveOmxRootForLaunch(cwd, process.env);
|
|
2328
|
+
const codexBaseEnv = {
|
|
2329
|
+
...process.env,
|
|
2330
|
+
...(codexHomeOverride ? { CODEX_HOME: codexHomeOverride } : {}),
|
|
2331
|
+
...(omxRootOverride ? { OMX_ROOT: omxRootOverride } : {}),
|
|
2332
|
+
};
|
|
2333
|
+
const codexEnvWithSession = {
|
|
2334
|
+
...codexBaseEnv,
|
|
2335
|
+
OMX_SESSION_ID: sessionId,
|
|
2336
|
+
[OMX_TMUX_HUD_OWNER_ENV]: "1",
|
|
2337
|
+
};
|
|
2216
2338
|
const codexEnv = workerLaunchArgs
|
|
2217
2339
|
? { ...codexEnvWithSession, [TEAM_WORKER_LAUNCH_ARGS_ENV]: workerLaunchArgs }
|
|
2218
2340
|
: codexEnvWithSession;
|
|
@@ -2303,7 +2425,7 @@ function runCodex(cwd, args, sessionId, workerDefaultModel, codexHomeOverride, n
|
|
|
2303
2425
|
let registeredHookName = null;
|
|
2304
2426
|
let registeredClientAttachedHookName = null;
|
|
2305
2427
|
try {
|
|
2306
|
-
const bootstrapSteps = buildDetachedSessionBootstrapSteps(sessionName, cwd, codexCmd, hudCmd, workerLaunchArgs, codexHomeOverride, notifyTempContractRaw, nativeWindows, sessionId, projectLocalCodexHomeForCleanup, runtimeCodexHomeForCleanup);
|
|
2428
|
+
const bootstrapSteps = buildDetachedSessionBootstrapSteps(sessionName, cwd, codexCmd, hudCmd, workerLaunchArgs, codexHomeOverride, notifyTempContractRaw, nativeWindows, sessionId, projectLocalCodexHomeForCleanup, runtimeCodexHomeForCleanup, omxRootOverride, process.env);
|
|
2307
2429
|
for (const step of bootstrapSteps) {
|
|
2308
2430
|
const output = execTmuxFileSync(step.args, {
|
|
2309
2431
|
stdio: "pipe",
|
|
@@ -2343,7 +2465,11 @@ function runCodex(cwd, args, sessionId, workerDefaultModel, codexHomeOverride, n
|
|
|
2343
2465
|
}
|
|
2344
2466
|
const stdio = finalizeStep.name === "attach-session" ? "inherit" : "ignore";
|
|
2345
2467
|
try {
|
|
2468
|
+
const startedAtMs = Date.now();
|
|
2346
2469
|
execTmuxFileSync(finalizeStep.args, { stdio });
|
|
2470
|
+
if (finalizeStep.name === "attach-session") {
|
|
2471
|
+
assertDetachedAttachDidNotNoop(sessionName, Date.now() - startedAtMs, process.env);
|
|
2472
|
+
}
|
|
2347
2473
|
}
|
|
2348
2474
|
catch (err) {
|
|
2349
2475
|
logCliOperationFailure(err);
|
|
@@ -2643,10 +2769,10 @@ async function emitNativeHookEvent(cwd, event, opts = {}) {
|
|
|
2643
2769
|
});
|
|
2644
2770
|
}
|
|
2645
2771
|
function notifyFallbackPidPath(cwd) {
|
|
2646
|
-
return join(cwd, "
|
|
2772
|
+
return join(omxRoot(cwd), "state", "notify-fallback.pid");
|
|
2647
2773
|
}
|
|
2648
2774
|
function hookDerivedWatcherPidPath(cwd) {
|
|
2649
|
-
return join(cwd, "
|
|
2775
|
+
return join(omxRoot(cwd), "state", "hook-derived-watcher.pid");
|
|
2650
2776
|
}
|
|
2651
2777
|
export function shouldDetachBackgroundHelper(env = process.env, platform = process.platform) {
|
|
2652
2778
|
// The long-running watcher/helper itself must stay detached so it can
|
|
@@ -2814,7 +2940,7 @@ async function startNotifyFallbackWatcher(cwd, options = {}) {
|
|
|
2814
2940
|
const notifyScript = resolveNotifyHookScript(pkgRoot);
|
|
2815
2941
|
if (!existsSync(watcherScript) || !existsSync(notifyScript))
|
|
2816
2942
|
return;
|
|
2817
|
-
await mkdir(join(cwd, "
|
|
2943
|
+
await mkdir(join(omxRoot(cwd), "state"), { recursive: true }).catch((error) => {
|
|
2818
2944
|
console.warn("[omx] warning: failed to create notify fallback watcher state directory", {
|
|
2819
2945
|
cwd,
|
|
2820
2946
|
error: error instanceof Error ? error.message : String(error),
|
|
@@ -2822,6 +2948,7 @@ async function startNotifyFallbackWatcher(cwd, options = {}) {
|
|
|
2822
2948
|
});
|
|
2823
2949
|
const watcherEnv = buildNotifyFallbackWatcherEnv(process.env, {
|
|
2824
2950
|
codexHomeOverride: options.codexHomeOverride,
|
|
2951
|
+
omxRootOverride: resolveOmxRootForLaunch(cwd, process.env),
|
|
2825
2952
|
enableAuthority: options.enableAuthority === true,
|
|
2826
2953
|
sessionId: options.sessionId,
|
|
2827
2954
|
});
|
|
@@ -2887,7 +3014,7 @@ async function startHookDerivedWatcher(cwd) {
|
|
|
2887
3014
|
});
|
|
2888
3015
|
}
|
|
2889
3016
|
}
|
|
2890
|
-
await mkdir(join(cwd, "
|
|
3017
|
+
await mkdir(join(omxRoot(cwd), "state"), { recursive: true }).catch((error) => {
|
|
2891
3018
|
console.warn("[omx] warning: failed to create hook-derived watcher state directory", {
|
|
2892
3019
|
cwd,
|
|
2893
3020
|
error: error instanceof Error ? error.message : String(error),
|