aicodeman 1.44.0 → 1.46.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/README.md +32 -8
- package/dist/agent-codex-identity.d.ts +26 -0
- package/dist/agent-codex-identity.d.ts.map +1 -0
- package/dist/agent-codex-identity.js +253 -0
- package/dist/agent-codex-identity.js.map +1 -0
- package/dist/agent-inspection.d.ts +32 -0
- package/dist/agent-inspection.d.ts.map +1 -0
- package/dist/agent-inspection.js +196 -0
- package/dist/agent-inspection.js.map +1 -0
- package/dist/agent-staging.d.ts +130 -0
- package/dist/agent-staging.d.ts.map +1 -0
- package/dist/agent-staging.js +312 -0
- package/dist/agent-staging.js.map +1 -0
- package/dist/case-rename.d.ts +65 -0
- package/dist/case-rename.d.ts.map +1 -0
- package/dist/case-rename.js +198 -0
- package/dist/case-rename.js.map +1 -0
- package/dist/cli-agent.d.ts +91 -3
- package/dist/cli-agent.d.ts.map +1 -1
- package/dist/cli-agent.js +501 -44
- package/dist/cli-agent.js.map +1 -1
- package/dist/cli-history.d.ts +20 -0
- package/dist/cli-history.d.ts.map +1 -0
- package/dist/cli-history.js +61 -0
- package/dist/cli-history.js.map +1 -0
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +6 -1
- package/dist/cli.js.map +1 -1
- package/dist/codex-rollout-format.d.ts +66 -0
- package/dist/codex-rollout-format.d.ts.map +1 -0
- package/dist/codex-rollout-format.js +111 -0
- package/dist/codex-rollout-format.js.map +1 -0
- package/dist/codex-transcript.d.ts +3 -0
- package/dist/codex-transcript.d.ts.map +1 -1
- package/dist/codex-transcript.js +13 -41
- package/dist/codex-transcript.js.map +1 -1
- package/dist/config/auth-config.d.ts +16 -1
- package/dist/config/auth-config.d.ts.map +1 -1
- package/dist/config/auth-config.js +16 -1
- package/dist/config/auth-config.js.map +1 -1
- package/dist/config/cli-registry/schema.d.ts +12 -7
- package/dist/config/cli-registry/schema.d.ts.map +1 -1
- package/dist/config/cli-registry/schema.js +26 -0
- package/dist/config/cli-registry/schema.js.map +1 -1
- package/dist/config/cli-registry/stock.d.ts.map +1 -1
- package/dist/config/cli-registry/stock.js +40 -1
- package/dist/config/cli-registry/stock.js.map +1 -1
- package/dist/config/cli-registry/types.d.ts +57 -0
- package/dist/config/cli-registry/types.d.ts.map +1 -1
- package/dist/config/server-timing.d.ts +6 -0
- package/dist/config/server-timing.d.ts.map +1 -1
- package/dist/config/server-timing.js +9 -0
- package/dist/config/server-timing.js.map +1 -1
- package/dist/daemon-control.d.ts +1 -0
- package/dist/daemon-control.d.ts.map +1 -1
- package/dist/daemon-control.js +2 -0
- package/dist/daemon-control.js.map +1 -1
- package/dist/deepseek-transcript.d.ts +9 -7
- package/dist/deepseek-transcript.d.ts.map +1 -1
- package/dist/deepseek-transcript.js +9 -7
- package/dist/deepseek-transcript.js.map +1 -1
- package/dist/docker-hosts.d.ts +8 -0
- package/dist/docker-hosts.d.ts.map +1 -1
- package/dist/docker-hosts.js +29 -0
- package/dist/docker-hosts.js.map +1 -1
- package/dist/git-fetch-scheduler.d.ts +124 -0
- package/dist/git-fetch-scheduler.d.ts.map +1 -0
- package/dist/git-fetch-scheduler.js +249 -0
- package/dist/git-fetch-scheduler.js.map +1 -0
- package/dist/git-fetch.d.ts +241 -0
- package/dist/git-fetch.d.ts.map +1 -0
- package/dist/git-fetch.js +392 -0
- package/dist/git-fetch.js.map +1 -0
- package/dist/git-workspace-status.d.ts +36 -1
- package/dist/git-workspace-status.d.ts.map +1 -1
- package/dist/git-workspace-status.js +42 -5
- package/dist/git-workspace-status.js.map +1 -1
- package/dist/hooks-config.d.ts +14 -2
- package/dist/hooks-config.d.ts.map +1 -1
- package/dist/hooks-config.js +39 -3
- package/dist/hooks-config.js.map +1 -1
- package/dist/host-sensors.d.ts +115 -0
- package/dist/host-sensors.d.ts.map +1 -0
- package/dist/host-sensors.js +457 -0
- package/dist/host-sensors.js.map +1 -0
- package/dist/local-history.d.ts +71 -0
- package/dist/local-history.d.ts.map +1 -0
- package/dist/local-history.js +750 -0
- package/dist/local-history.js.map +1 -0
- package/dist/mcp-server.d.ts.map +1 -1
- package/dist/mcp-server.js +2 -2
- package/dist/mcp-server.js.map +1 -1
- package/dist/mux-interface.d.ts +5 -2
- package/dist/mux-interface.d.ts.map +1 -1
- package/dist/prompt-cache-keepwarm.d.ts.map +1 -1
- package/dist/prompt-cache-keepwarm.js +5 -3
- package/dist/prompt-cache-keepwarm.js.map +1 -1
- package/dist/remote-hosts.d.ts +7 -0
- package/dist/remote-hosts.d.ts.map +1 -1
- package/dist/remote-hosts.js +17 -3
- package/dist/remote-hosts.js.map +1 -1
- package/dist/remote-pane-history.d.ts.map +1 -1
- package/dist/remote-pane-history.js +2 -2
- package/dist/remote-pane-history.js.map +1 -1
- package/dist/session.d.ts +113 -0
- package/dist/session.d.ts.map +1 -1
- package/dist/session.js +354 -13
- package/dist/session.js.map +1 -1
- package/dist/terminal-input-classifier.d.ts +8 -0
- package/dist/terminal-input-classifier.d.ts.map +1 -0
- package/dist/terminal-input-classifier.js +60 -0
- package/dist/terminal-input-classifier.js.map +1 -0
- package/dist/tmux-manager.d.ts +30 -4
- package/dist/tmux-manager.d.ts.map +1 -1
- package/dist/tmux-manager.js +101 -21
- package/dist/tmux-manager.js.map +1 -1
- package/dist/tmux-prefix-table.d.ts +37 -5
- package/dist/tmux-prefix-table.d.ts.map +1 -1
- package/dist/tmux-prefix-table.js +40 -5
- package/dist/tmux-prefix-table.js.map +1 -1
- package/dist/tui/tui-app.d.ts +8 -1
- package/dist/tui/tui-app.d.ts.map +1 -1
- package/dist/tui/tui-app.js +49 -12
- package/dist/tui/tui-app.js.map +1 -1
- package/dist/tui/tui-client.d.ts +90 -3
- package/dist/tui/tui-client.d.ts.map +1 -1
- package/dist/tui/tui-client.js +195 -26
- package/dist/tui/tui-client.js.map +1 -1
- package/dist/types/session.d.ts +15 -0
- package/dist/types/session.d.ts.map +1 -1
- package/dist/types/session.js.map +1 -1
- package/dist/web/agent-inbox-persistence.d.ts +52 -0
- package/dist/web/agent-inbox-persistence.d.ts.map +1 -0
- package/dist/web/agent-inbox-persistence.js +139 -0
- package/dist/web/agent-inbox-persistence.js.map +1 -0
- package/dist/web/agent-inbox.d.ts +140 -0
- package/dist/web/agent-inbox.d.ts.map +1 -0
- package/dist/web/agent-inbox.js +258 -0
- package/dist/web/agent-inbox.js.map +1 -0
- package/dist/web/middleware/auth.d.ts +2 -0
- package/dist/web/middleware/auth.d.ts.map +1 -1
- package/dist/web/middleware/auth.js +145 -52
- package/dist/web/middleware/auth.js.map +1 -1
- package/dist/web/network-auth-policy.d.ts +13 -3
- package/dist/web/network-auth-policy.d.ts.map +1 -1
- package/dist/web/network-auth-policy.js +15 -3
- package/dist/web/network-auth-policy.js.map +1 -1
- package/dist/web/ports/infra-port.d.ts +2 -0
- package/dist/web/ports/infra-port.d.ts.map +1 -1
- package/dist/web/public/admin-ui.js.gz +0 -0
- package/dist/web/public/api-client.c9b1cddc.js.gz +0 -0
- package/dist/web/public/app.3093527f.js +43 -0
- package/dist/web/public/app.3093527f.js.br +0 -0
- package/dist/web/public/app.3093527f.js.gz +0 -0
- package/dist/web/public/approvals-ui.js.gz +0 -0
- package/dist/web/public/{constants.4866ecc3.js → constants.affcdde6.js} +622 -12
- package/dist/web/public/constants.affcdde6.js.br +0 -0
- package/dist/web/public/constants.affcdde6.js.gz +0 -0
- package/dist/web/public/cron-ui.js.gz +0 -0
- package/dist/web/public/entrance-animations.js.gz +0 -0
- package/dist/web/public/git-status-ui.js +88 -5
- package/dist/web/public/git-status-ui.js.br +0 -0
- package/dist/web/public/git-status-ui.js.gz +0 -0
- package/dist/web/public/header-divider.eb2d2463.js +1 -0
- package/dist/web/public/header-divider.eb2d2463.js.br +0 -0
- package/dist/web/public/header-divider.eb2d2463.js.gz +0 -0
- package/dist/web/public/home-sessions.js.gz +0 -0
- package/dist/web/public/host-wake-ui.js.gz +0 -0
- package/dist/web/public/i18n.70265257.js +2 -0
- package/dist/web/public/i18n.70265257.js.br +0 -0
- package/dist/web/public/i18n.70265257.js.gz +0 -0
- package/dist/web/public/image-input.941386e7.js.gz +0 -0
- package/dist/web/public/index.html +170 -16
- package/dist/web/public/index.html.br +0 -0
- package/dist/web/public/index.html.gz +0 -0
- package/dist/web/public/input-cjk.8bc46081.js.gz +0 -0
- package/dist/web/public/keyboard-accessory.4e8b20ac.js.gz +0 -0
- package/dist/web/public/{mobile-handlers.44adaa07.js → mobile-handlers.f7c3f692.js} +26 -2
- package/dist/web/public/mobile-handlers.f7c3f692.js.br +0 -0
- package/dist/web/public/mobile-handlers.f7c3f692.js.gz +0 -0
- package/dist/web/public/mobile-ime-preview.2dbaf262.js.gz +0 -0
- package/dist/web/public/mobile-overview.js.gz +0 -0
- package/dist/web/public/mobile.1bbd2d67.css +1 -0
- package/dist/web/public/mobile.1bbd2d67.css.br +0 -0
- package/dist/web/public/mobile.1bbd2d67.css.gz +0 -0
- package/dist/web/public/notification-manager.feb82c04.js.gz +0 -0
- package/dist/web/public/orchestrator-panel.js.gz +0 -0
- package/dist/web/public/{panels-ui.cbb24ba1.js → panels-ui.4a56ee63.js} +76 -70
- package/dist/web/public/panels-ui.4a56ee63.js.br +0 -0
- package/dist/web/public/panels-ui.4a56ee63.js.gz +0 -0
- package/dist/web/public/ralph-panel.b350e2ef.js.gz +0 -0
- package/dist/web/public/ralph-wizard.b6c0dd19.js.gz +0 -0
- package/dist/web/public/readmymind-ui.js.gz +0 -0
- package/dist/web/public/reboot-restore-ui.js.gz +0 -0
- package/dist/web/public/respawn-ui.d7adcf6a.js.gz +0 -0
- package/dist/web/public/sanitize-html.e7147e76.js.gz +0 -0
- package/dist/web/public/session-lineage.js.gz +0 -0
- package/dist/web/public/session-ui.186f9419.js +106 -0
- package/dist/web/public/session-ui.186f9419.js.br +0 -0
- package/dist/web/public/session-ui.186f9419.js.gz +0 -0
- package/dist/web/public/settings-ui.a191154e.js +106 -0
- package/dist/web/public/settings-ui.a191154e.js.br +0 -0
- package/dist/web/public/settings-ui.a191154e.js.gz +0 -0
- package/dist/web/public/spreadsheet-preview-worker.js.gz +0 -0
- package/dist/web/public/spreadsheet-preview.75c751de.js.gz +0 -0
- package/dist/web/public/spreadsheet-xlsx-core.js.gz +0 -0
- package/dist/web/public/styles.7238eae8.css +1 -0
- package/dist/web/public/styles.7238eae8.css.br +0 -0
- package/dist/web/public/styles.7238eae8.css.gz +0 -0
- package/dist/web/public/subagent-windows.07277a58.js.gz +0 -0
- package/dist/web/public/sw.js +2 -2
- package/dist/web/public/sw.js.br +0 -0
- package/dist/web/public/sw.js.gz +0 -0
- package/dist/web/public/tab-layout-browser.2d6189f7.js.gz +0 -0
- package/dist/web/public/{tab-rail-resize.7157e0bd.js → tab-rail-resize.b5cdceaf.js} +1 -1
- package/dist/web/public/tab-rail-resize.b5cdceaf.js.br +0 -0
- package/dist/web/public/tab-rail-resize.b5cdceaf.js.gz +0 -0
- package/dist/web/public/terminal-keycode229-recovery.af09f99a.js.gz +0 -0
- package/dist/web/public/terminal-split.js.gz +0 -0
- package/dist/web/public/terminal-tile.js +10 -1
- package/dist/web/public/terminal-tile.js.br +0 -0
- package/dist/web/public/terminal-tile.js.gz +0 -0
- package/dist/web/public/terminal-ui.7e787829.js +4 -0
- package/dist/web/public/terminal-ui.7e787829.js.br +0 -0
- package/dist/web/public/terminal-ui.7e787829.js.gz +0 -0
- package/dist/web/public/tile-grid.js.gz +0 -0
- package/dist/web/public/ultracode-panel.js.gz +0 -0
- package/dist/web/public/ultracode-windows.js.gz +0 -0
- package/dist/web/public/vendor/dompurify.min.js.gz +0 -0
- package/dist/web/public/vendor/exceljs.min.js.gz +0 -0
- package/dist/web/public/vendor/fflate.min.js.gz +0 -0
- package/dist/web/public/vendor/marked.min.js.gz +0 -0
- package/dist/web/public/vendor/xterm-addon-fit.min.js.gz +0 -0
- package/dist/web/public/vendor/xterm-addon-serialize.min.js.gz +0 -0
- package/dist/web/public/vendor/xterm-addon-unicode11.min.js.gz +0 -0
- package/dist/web/public/vendor/xterm-addon-webgl.min.js.gz +0 -0
- package/dist/web/public/vendor/{xterm-predictive-echo.ae5e3d5d.js → xterm-predictive-echo.276b11d9.js} +1 -1
- package/dist/web/public/vendor/xterm-predictive-echo.276b11d9.js.br +0 -0
- package/dist/web/public/vendor/xterm-predictive-echo.276b11d9.js.gz +0 -0
- package/dist/web/public/vendor/xterm-zerolag-input.1be42307.js +5 -0
- package/dist/web/public/vendor/xterm-zerolag-input.1be42307.js.br +0 -0
- package/dist/web/public/vendor/xterm-zerolag-input.1be42307.js.gz +0 -0
- package/dist/web/public/vendor/xterm.css.gz +0 -0
- package/dist/web/public/vendor/xterm.min.js.gz +0 -0
- package/dist/web/public/voice-input.2342c37b.js.gz +0 -0
- package/dist/web/public/voice-pcm-worklet.js.gz +0 -0
- package/dist/web/public/webview-tabs.js.gz +0 -0
- package/dist/web/public/whats-new.json +9 -9
- package/dist/web/route-helpers.d.ts +57 -6
- package/dist/web/route-helpers.d.ts.map +1 -1
- package/dist/web/route-helpers.js +72 -4
- package/dist/web/route-helpers.js.map +1 -1
- package/dist/web/routes/agent-session-routes.d.ts +20 -0
- package/dist/web/routes/agent-session-routes.d.ts.map +1 -0
- package/dist/web/routes/agent-session-routes.js +160 -0
- package/dist/web/routes/agent-session-routes.js.map +1 -0
- package/dist/web/routes/case-routes.d.ts.map +1 -1
- package/dist/web/routes/case-routes.js +203 -16
- package/dist/web/routes/case-routes.js.map +1 -1
- package/dist/web/routes/config-backup-routes.js +2 -2
- package/dist/web/routes/config-backup-routes.js.map +1 -1
- package/dist/web/routes/git-status-routes.d.ts +21 -7
- package/dist/web/routes/git-status-routes.d.ts.map +1 -1
- package/dist/web/routes/git-status-routes.js +78 -12
- package/dist/web/routes/git-status-routes.js.map +1 -1
- package/dist/web/routes/inbox-routes.d.ts +43 -0
- package/dist/web/routes/inbox-routes.d.ts.map +1 -0
- package/dist/web/routes/inbox-routes.js +148 -0
- package/dist/web/routes/inbox-routes.js.map +1 -0
- package/dist/web/routes/index.d.ts +2 -0
- package/dist/web/routes/index.d.ts.map +1 -1
- package/dist/web/routes/index.js +2 -0
- package/dist/web/routes/index.js.map +1 -1
- package/dist/web/routes/ralph-routes.d.ts.map +1 -1
- package/dist/web/routes/ralph-routes.js +7 -16
- package/dist/web/routes/ralph-routes.js.map +1 -1
- package/dist/web/routes/session-routes.d.ts.map +1 -1
- package/dist/web/routes/session-routes.js +120 -74
- package/dist/web/routes/session-routes.js.map +1 -1
- package/dist/web/routes/system-routes.d.ts.map +1 -1
- package/dist/web/routes/system-routes.js +107 -59
- package/dist/web/routes/system-routes.js.map +1 -1
- package/dist/web/routes/ws-routes.d.ts +5 -0
- package/dist/web/routes/ws-routes.d.ts.map +1 -1
- package/dist/web/routes/ws-routes.js +84 -47
- package/dist/web/routes/ws-routes.js.map +1 -1
- package/dist/web/schemas.d.ts +56 -7
- package/dist/web/schemas.d.ts.map +1 -1
- package/dist/web/schemas.js +88 -1
- package/dist/web/schemas.js.map +1 -1
- package/dist/web/sensitive-path.d.ts.map +1 -1
- package/dist/web/sensitive-path.js +2 -0
- package/dist/web/sensitive-path.js.map +1 -1
- package/dist/web/server.d.ts +7 -2
- package/dist/web/server.d.ts.map +1 -1
- package/dist/web/server.js +144 -16
- package/dist/web/server.js.map +1 -1
- package/dist/web/session-wait-registry.d.ts +48 -4
- package/dist/web/session-wait-registry.d.ts.map +1 -1
- package/dist/web/session-wait-registry.js +144 -6
- package/dist/web/session-wait-registry.js.map +1 -1
- package/dist/web/settings-writer.d.ts +47 -0
- package/dist/web/settings-writer.d.ts.map +1 -0
- package/dist/web/settings-writer.js +110 -0
- package/dist/web/settings-writer.js.map +1 -0
- package/dist/web/sse-events.d.ts +4 -1
- package/dist/web/sse-events.d.ts.map +1 -1
- package/dist/web/sse-events.js +4 -1
- package/dist/web/sse-events.js.map +1 -1
- package/package.json +1 -1
- package/skills/codeman/SKILL.md +30 -8
- package/skills/codeman/preamble.sh +3 -3
- package/skills/codeman/reference/endpoints.md +24 -3
- package/skills/codeman/reference/history.md +84 -0
- package/skills/codeman/reference/inspection-and-staging.md +152 -0
- package/skills/codeman/reference/messaging.md +1 -1
- package/skills/codeman/reference/verbs.md +65 -3
- package/dist/web/public/app.9314ee60.js +0 -43
- package/dist/web/public/app.9314ee60.js.br +0 -0
- package/dist/web/public/app.9314ee60.js.gz +0 -0
- package/dist/web/public/constants.4866ecc3.js.br +0 -0
- package/dist/web/public/constants.4866ecc3.js.gz +0 -0
- package/dist/web/public/i18n.22ca902b.js +0 -2
- package/dist/web/public/i18n.22ca902b.js.br +0 -0
- package/dist/web/public/i18n.22ca902b.js.gz +0 -0
- package/dist/web/public/mobile-handlers.44adaa07.js.br +0 -0
- package/dist/web/public/mobile-handlers.44adaa07.js.gz +0 -0
- package/dist/web/public/mobile.12fb18de.css +0 -1
- package/dist/web/public/mobile.12fb18de.css.br +0 -0
- package/dist/web/public/mobile.12fb18de.css.gz +0 -0
- package/dist/web/public/panels-ui.cbb24ba1.js.br +0 -0
- package/dist/web/public/panels-ui.cbb24ba1.js.gz +0 -0
- package/dist/web/public/session-ui.9c1f009b.js +0 -104
- package/dist/web/public/session-ui.9c1f009b.js.br +0 -0
- package/dist/web/public/session-ui.9c1f009b.js.gz +0 -0
- package/dist/web/public/settings-ui.fea9ddae.js +0 -106
- package/dist/web/public/settings-ui.fea9ddae.js.br +0 -0
- package/dist/web/public/settings-ui.fea9ddae.js.gz +0 -0
- package/dist/web/public/styles.e096fcd6.css +0 -1
- package/dist/web/public/styles.e096fcd6.css.br +0 -0
- package/dist/web/public/styles.e096fcd6.css.gz +0 -0
- package/dist/web/public/tab-rail-resize.7157e0bd.js.br +0 -0
- package/dist/web/public/tab-rail-resize.7157e0bd.js.gz +0 -0
- package/dist/web/public/terminal-ui.68dbd352.js +0 -2
- package/dist/web/public/terminal-ui.68dbd352.js.br +0 -0
- package/dist/web/public/terminal-ui.68dbd352.js.gz +0 -0
- package/dist/web/public/vendor/xterm-predictive-echo.ae5e3d5d.js.br +0 -0
- package/dist/web/public/vendor/xterm-predictive-echo.ae5e3d5d.js.gz +0 -0
- package/dist/web/public/vendor/xterm-zerolag-input.0b69623c.js +0 -4
- package/dist/web/public/vendor/xterm-zerolag-input.0b69623c.js.br +0 -0
- package/dist/web/public/vendor/xterm-zerolag-input.0b69623c.js.gz +0 -0
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/** @fileoverview Distinguish complete terminal focus/mouse reports from keyboard-bearing input. */
|
|
2
|
+
const FOCUS_REPORT_LENGTH = 3;
|
|
3
|
+
const X10_REPORT_LENGTH = 6;
|
|
4
|
+
function sgrMouseReportLength(rest) {
|
|
5
|
+
if (!rest.startsWith('\x1b[<'))
|
|
6
|
+
return 0;
|
|
7
|
+
let offset = 3;
|
|
8
|
+
for (let field = 0; field < 3; field += 1) {
|
|
9
|
+
const digitStart = offset;
|
|
10
|
+
while (offset < rest.length && rest.charCodeAt(offset) >= 48 && rest.charCodeAt(offset) <= 57) {
|
|
11
|
+
offset += 1;
|
|
12
|
+
}
|
|
13
|
+
if (offset === digitStart)
|
|
14
|
+
return 0;
|
|
15
|
+
if (field < 2) {
|
|
16
|
+
if (rest[offset] !== ';')
|
|
17
|
+
return 0;
|
|
18
|
+
offset += 1;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
return rest[offset] === 'M' || rest[offset] === 'm' ? offset + 1 : 0;
|
|
22
|
+
}
|
|
23
|
+
function x10MouseReportLength(rest) {
|
|
24
|
+
if (!rest.startsWith('\x1b[M') || rest.length < X10_REPORT_LENGTH)
|
|
25
|
+
return 0;
|
|
26
|
+
const button = rest.charCodeAt(3);
|
|
27
|
+
const x = rest.charCodeAt(4);
|
|
28
|
+
const y = rest.charCodeAt(5);
|
|
29
|
+
if (button < 32 || button > 255 || x < 33 || x > 255 || y < 33 || y > 255)
|
|
30
|
+
return 0;
|
|
31
|
+
return X10_REPORT_LENGTH;
|
|
32
|
+
}
|
|
33
|
+
function terminalReportLengthAt(data, offset) {
|
|
34
|
+
const rest = data.slice(offset);
|
|
35
|
+
if (rest.startsWith('\x1b[I') || rest.startsWith('\x1b[O'))
|
|
36
|
+
return FOCUS_REPORT_LENGTH;
|
|
37
|
+
const sgrLength = sgrMouseReportLength(rest);
|
|
38
|
+
if (sgrLength > 0)
|
|
39
|
+
return sgrLength;
|
|
40
|
+
return x10MouseReportLength(rest);
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Whether terminal input contains any keyboard-bearing bytes.
|
|
44
|
+
*
|
|
45
|
+
* Returns false only when every byte is consumed as an allowlisted mouse or
|
|
46
|
+
* focus report. Unknown, malformed, mixed, and empty input fails closed.
|
|
47
|
+
*/
|
|
48
|
+
export function isKeyboardTerminalInput(data) {
|
|
49
|
+
if (data.length === 0)
|
|
50
|
+
return true;
|
|
51
|
+
let offset = 0;
|
|
52
|
+
while (offset < data.length) {
|
|
53
|
+
const reportLength = terminalReportLengthAt(data, offset);
|
|
54
|
+
if (reportLength === 0)
|
|
55
|
+
return true;
|
|
56
|
+
offset += reportLength;
|
|
57
|
+
}
|
|
58
|
+
return false;
|
|
59
|
+
}
|
|
60
|
+
//# sourceMappingURL=terminal-input-classifier.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"terminal-input-classifier.js","sourceRoot":"","sources":["../src/terminal-input-classifier.ts"],"names":[],"mappings":"AAAA,mGAAmG;AACnG,MAAM,mBAAmB,GAAG,CAAC,CAAC;AAC9B,MAAM,iBAAiB,GAAG,CAAC,CAAC;AAE5B,SAAS,oBAAoB,CAAC,IAAY;IACxC,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC;QAAE,OAAO,CAAC,CAAC;IAEzC,IAAI,MAAM,GAAG,CAAC,CAAC;IACf,KAAK,IAAI,KAAK,GAAG,CAAC,EAAE,KAAK,GAAG,CAAC,EAAE,KAAK,IAAI,CAAC,EAAE,CAAC;QAC1C,MAAM,UAAU,GAAG,MAAM,CAAC;QAC1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AC,KAAK,CAAC,MAAM,CAAC,CAAC;IAChC,IAAI,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC,IAAI,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC;QAAE,OAAO,mBAAmB,CAAC;IAEvF,MAAM,SAAS,GAAG,oBAAoB,CAAC,IAAI,CAAC,CAAC;IAC7C,IAAI,SAAS,GAAG,CAAC;QAAE,OAAO,SAAS,CAAC;IAEpC,OAAO,oBAAoB,CAAC,IAAI,CAAC,CAAC;AACpC,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,uBAAuB,CAAC,IAAY;IAClD,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,IAAI,CAAC;IAEnC,IAAI,MAAM,GAAG,CAAC,CAAC;IACf,OAAO,MAAM,GAAG,IAAI,CAAC,MAAM,EAAE,CAAC;QAC5B,MAAM,YAAY,GAAG,sBAAsB,CAAC,IAAI,EAAE,MAAM,CAAC,CAAC;QAC1D,IAAI,YAAY,KAAK,CAAC;YAAE,OAAO,IAAI,CAAC;QACpC,MAAM,IAAI,YAAY,CAAC;IACzB,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC"}
|
package/dist/tmux-manager.d.ts
CHANGED
|
@@ -131,9 +131,11 @@ export interface PasteTextCommands {
|
|
|
131
131
|
}
|
|
132
132
|
/**
|
|
133
133
|
* Escape a final `;` for tmux. tmux splits commands on an argument that ENDS in
|
|
134
|
-
* `;` (`set-buffer -- 'a;'` stores `a`, `send-keys -l 'a;'` types `a`, a lone `;`
|
|
134
|
+
* `;` (`set-buffer -- 'a;'` stores `a`, `send-keys -l -- 'a;'` types `a`, a lone `;`
|
|
135
135
|
* is no argument at all); a final `\;` is its escape for a literal `;`. A `;`
|
|
136
|
-
* anywhere else in the argument is literal already.
|
|
136
|
+
* anywhere else in the argument is literal already. Every `send-keys -l` passes
|
|
137
|
+
* `--` before the text, like `set-buffer`, or tmux parses a text that starts with
|
|
138
|
+
* `-` as its own options. Exported for unit testing.
|
|
137
139
|
*/
|
|
138
140
|
export declare function escapeTmuxTrailingSemicolon(text: string): string;
|
|
139
141
|
/**
|
|
@@ -272,6 +274,16 @@ export declare function hasVisibleContent(capture: string): boolean;
|
|
|
272
274
|
* genuinely share.
|
|
273
275
|
*/
|
|
274
276
|
export declare function formatCursorRestore(geometry: PaneCursorGeometry): string;
|
|
277
|
+
/**
|
|
278
|
+
* Split the output of `capture-pane -p \; display-message -p '<cursor format>'`
|
|
279
|
+
* into the captured rows and the cursor line, which tmux prints last. Null unless
|
|
280
|
+
* that last line has the cursor query's shape (four leading integers), so a query
|
|
281
|
+
* that printed nothing can never have the frame's own last row taken for it.
|
|
282
|
+
*/
|
|
283
|
+
export declare function splitFrameAndCursor(output: string): {
|
|
284
|
+
frame: string;
|
|
285
|
+
cursor: string;
|
|
286
|
+
} | null;
|
|
275
287
|
export declare function formatPaneSnapshot(lines: string[], geometry: {
|
|
276
288
|
cols: number;
|
|
277
289
|
rows: number;
|
|
@@ -368,7 +380,9 @@ export declare function remoteTmuxLocation(remote: SessionRemote, sessionId: str
|
|
|
368
380
|
* ssh -o BatchMode=yes -t [<COD-107 connection opts>] user@host \
|
|
369
381
|
* 'tmux -L codeman-remote new-session -A -s codeman-ssh-<id> -c <path> "cd <path> && exec <cli>" \
|
|
370
382
|
* \; set -t codeman-ssh-<id> status off \; set -t codeman-ssh-<id> mouse off \
|
|
371
|
-
* \; set -t codeman-ssh-<id> prefix C-q \; set -s escape-time 0
|
|
383
|
+
* \; set -t codeman-ssh-<id> prefix C-q \; set -s escape-time 0 \; \
|
|
384
|
+
* bind-key -T prefix C-q send-prefix \; unbind-key -a -T prefix \; \
|
|
385
|
+
* bind-key -T prefix C-q send-prefix \; set -t codeman-ssh-<id> remain-on-exit failed'
|
|
372
386
|
*
|
|
373
387
|
* COD-107 — the connection options (`-p`, `-i`, `-J`, SOCKS `-o ProxyCommand`,
|
|
374
388
|
* arbitrary `-o`) come from the shared `buildSshConnectionArgs(remote)`, so the
|
|
@@ -927,7 +941,9 @@ export declare class TmuxManager extends EventEmitter implements TerminalMultipl
|
|
|
927
941
|
* - `Enter` key is sent as a SEPARATE tmux invocation after a small delay
|
|
928
942
|
* - Ink (Claude CLI) needs text and Enter split to avoid treating Enter as a newline
|
|
929
943
|
*/
|
|
930
|
-
sendInput(sessionId: string, input: string
|
|
944
|
+
sendInput(sessionId: string, input: string, options?: {
|
|
945
|
+
beforeDispatch?: () => boolean;
|
|
946
|
+
}): Promise<boolean>;
|
|
931
947
|
/**
|
|
932
948
|
* How {@link sendInput} reaches tmux, or null where it must not (vitest). Split
|
|
933
949
|
* out like {@link readPaneRows}: with the test-mode gate at the top of sendInput,
|
|
@@ -996,6 +1012,16 @@ export declare class TmuxManager extends EventEmitter implements TerminalMultipl
|
|
|
996
1012
|
styles?: boolean;
|
|
997
1013
|
}): string | null;
|
|
998
1014
|
capturePaneBuffer(muxName: string, paneTarget?: string, opts?: PaneCaptureOptions): string | null;
|
|
1015
|
+
/**
|
|
1016
|
+
* How {@link capturePaneBuffer} runs tmux, or null where it must not (vitest).
|
|
1017
|
+
* Split out like {@link inputRunner} so a test subclass can count and script the
|
|
1018
|
+
* calls a capture makes.
|
|
1019
|
+
*/
|
|
1020
|
+
protected captureRunner(): ((cmd: string, opts: {
|
|
1021
|
+
encoding: 'utf-8';
|
|
1022
|
+
timeout: number;
|
|
1023
|
+
maxBuffer?: number;
|
|
1024
|
+
}) => string) | null;
|
|
999
1025
|
/**
|
|
1000
1026
|
* Capture the active pane for a tmux session.
|
|
1001
1027
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tmux-manager.d.ts","sourceRoot":"","sources":["../src/tmux-manager.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAiB3C,OAAO,EACL,YAAY,EACZ,sBAAsB,EAGtB,KAAK,QAAQ,EACb,KAAK,U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IxC,mBAAmB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO;IAkB7C,YAAY,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,OAAO;IAyBlE,WAAW,IAAI,OAAO;IAItB;;OAEG;IACH,MAAM,CAAC,eAAe,IAAI,OAAO;CAQlC"}
|
package/dist/tmux-manager.js
CHANGED
|
@@ -36,7 +36,7 @@ import { missingCliMessage, resolveCliBinDir } from './utils/cli-resolver.js';
|
|
|
36
36
|
import { buildSpawnCommandFromRegistry, configSetenvValues, launchGatePasses, legacyConfigForMode, } from './session-cli-registry-bridge.js';
|
|
37
37
|
import { keepWarmOn } from './prompt-cache-keepwarm.js';
|
|
38
38
|
import { resolveStatusLineCliCommand, readPlanUsageTelemetryEnabled, readKeepWarmSettings, findEffectiveUserStatusLineCommand, } from './hooks-config.js';
|
|
39
|
-
import { buildSshConnectionArgs, defaultRemoteCommandForMode, remoteLoginShellCommand, remoteSshTarget, remoteTmuxSessionAlive, } from './remote-hosts.js';
|
|
39
|
+
import { buildSshConnectionArgs, defaultRemoteCommandForMode, remoteLoginShellCommand, remoteSshTarget, remoteTmuxSessionAlive, withRemoteTmuxPath, } from './remote-hosts.js';
|
|
40
40
|
import { buildDockerBaseArgs, buildDockerCreateArgs, containerApiUrl, CONTAINER_HOME, defaultDockerCommandForMode, hostGatewayAlias, resolveDockerClaudeArtifacts, resolveDockerCredentialArtifacts, resolveDockerDaemonMountSource, } from './docker-hosts.js';
|
|
41
41
|
import { wrapWithNice, SAFE_PATH_PATTERN, resolveLocalShell, loginShellArgs, waitForProcessesExit, } from './utils/index.js';
|
|
42
42
|
import { decideReconnect, advanceBackoff, freshReconnectState, resetReconnectState, } from './remote-reconnect.js';
|
|
@@ -45,7 +45,7 @@ import { decideReconnect, advanceBackoff, freshReconnectState, resetReconnectSta
|
|
|
45
45
|
// ============================================================================
|
|
46
46
|
import { EXEC_TIMEOUT_MS } from './config/exec-timeout.js';
|
|
47
47
|
import { ensureDeepSeekStatusShim } from './deepseek-status-shim.js';
|
|
48
|
-
import { restrictTmuxPrefixTable } from './tmux-prefix-table.js';
|
|
48
|
+
import { NESTED_TMUX_PREFIX, nestedPrefixTableResetCommands, restrictTmuxPrefixTable } from './tmux-prefix-table.js';
|
|
49
49
|
/** How long a cached process snapshot stays usable. */
|
|
50
50
|
const PROC_SNAPSHOT_TTL_MS = 2000;
|
|
51
51
|
/**
|
|
@@ -319,9 +319,11 @@ export function resolveTmuxPaneTarget(muxName, paneTarget) {
|
|
|
319
319
|
let submitBufferSeq = 0;
|
|
320
320
|
/**
|
|
321
321
|
* Escape a final `;` for tmux. tmux splits commands on an argument that ENDS in
|
|
322
|
-
* `;` (`set-buffer -- 'a;'` stores `a`, `send-keys -l 'a;'` types `a`, a lone `;`
|
|
322
|
+
* `;` (`set-buffer -- 'a;'` stores `a`, `send-keys -l -- 'a;'` types `a`, a lone `;`
|
|
323
323
|
* is no argument at all); a final `\;` is its escape for a literal `;`. A `;`
|
|
324
|
-
* anywhere else in the argument is literal already.
|
|
324
|
+
* anywhere else in the argument is literal already. Every `send-keys -l` passes
|
|
325
|
+
* `--` before the text, like `set-buffer`, or tmux parses a text that starts with
|
|
326
|
+
* `-` as its own options. Exported for unit testing.
|
|
325
327
|
*/
|
|
326
328
|
export function escapeTmuxTrailingSemicolon(text) {
|
|
327
329
|
return text.endsWith(';') ? `${text.slice(0, -1)}\\;` : text;
|
|
@@ -783,6 +785,20 @@ export function formatCursorRestore(geometry) {
|
|
|
783
785
|
// last row's text ended.
|
|
784
786
|
return `${up > 0 ? `\x1b[${up}A` : ''}\r${right > 0 ? `\x1b[${right}C` : ''}`;
|
|
785
787
|
}
|
|
788
|
+
/**
|
|
789
|
+
* Split the output of `capture-pane -p \; display-message -p '<cursor format>'`
|
|
790
|
+
* into the captured rows and the cursor line, which tmux prints last. Null unless
|
|
791
|
+
* that last line has the cursor query's shape (four leading integers), so a query
|
|
792
|
+
* that printed nothing can never have the frame's own last row taken for it.
|
|
793
|
+
*/
|
|
794
|
+
export function splitFrameAndCursor(output) {
|
|
795
|
+
const body = output.endsWith('\n') ? output.slice(0, -1) : output;
|
|
796
|
+
const split = body.lastIndexOf('\n');
|
|
797
|
+
const cursor = body.slice(split + 1);
|
|
798
|
+
if (!/^\d+ \d+ \d+ \d+(?: |$)/.test(cursor))
|
|
799
|
+
return null;
|
|
800
|
+
return { frame: body.slice(0, split + 1), cursor };
|
|
801
|
+
}
|
|
786
802
|
export function formatPaneSnapshot(lines, geometry) {
|
|
787
803
|
const cols = Math.max(1, geometry.cols);
|
|
788
804
|
// Paint the full pane width. Earlier this dropped the rightmost column
|
|
@@ -974,7 +990,9 @@ export function remoteTmuxLocation(remote, sessionId) {
|
|
|
974
990
|
* ssh -o BatchMode=yes -t [<COD-107 connection opts>] user@host \
|
|
975
991
|
* 'tmux -L codeman-remote new-session -A -s codeman-ssh-<id> -c <path> "cd <path> && exec <cli>" \
|
|
976
992
|
* \; set -t codeman-ssh-<id> status off \; set -t codeman-ssh-<id> mouse off \
|
|
977
|
-
* \; set -t codeman-ssh-<id> prefix C-q \; set -s escape-time 0
|
|
993
|
+
* \; set -t codeman-ssh-<id> prefix C-q \; set -s escape-time 0 \; \
|
|
994
|
+
* bind-key -T prefix C-q send-prefix \; unbind-key -a -T prefix \; \
|
|
995
|
+
* bind-key -T prefix C-q send-prefix \; set -t codeman-ssh-<id> remain-on-exit failed'
|
|
978
996
|
*
|
|
979
997
|
* COD-107 — the connection options (`-p`, `-i`, `-J`, SOCKS `-o ProxyCommand`,
|
|
980
998
|
* arbitrary `-o`) come from the shared `buildSshConnectionArgs(remote)`, so the
|
|
@@ -1079,7 +1097,7 @@ export function buildRemoteLaunchCommand(options) {
|
|
|
1079
1097
|
`tmux -L ${REMOTE_TMUX_SOCKET} new-session -A -s ${remoteName} -c ${shellescape(remote.remotePath)} ${shellescape(paneCommand)}`,
|
|
1080
1098
|
`set -t ${remoteName} status off`,
|
|
1081
1099
|
`set -t ${remoteName} mouse off`,
|
|
1082
|
-
`set -t ${remoteName} prefix
|
|
1100
|
+
`set -t ${remoteName} prefix ${NESTED_TMUX_PREFIX}`,
|
|
1083
1101
|
'set -s escape-time 0',
|
|
1084
1102
|
// COD-106 — shared/collaborative sessions: tmux defaults to sizing a window
|
|
1085
1103
|
// to the SMALLEST attached client, so two Codemans at different viewports
|
|
@@ -1088,6 +1106,15 @@ export function buildRemoteLaunchCommand(options) {
|
|
|
1088
1106
|
// Per-session scoped (`set -t <name>`, matching #145's hardening) so a shared
|
|
1089
1107
|
// remote tmux server's other sessions keep their own sizing behavior.
|
|
1090
1108
|
`set -t ${remoteName} window-size latest`,
|
|
1109
|
+
// The prefix TABLE is server-global (unlike `prefix C-q`, which is per
|
|
1110
|
+
// session). This socket is dedicated to Codeman's owned sessions, so the
|
|
1111
|
+
// same reduction as the local socket applies: Ctrl+Q then )/(/s/w/L must
|
|
1112
|
+
// not switch-client / choose-tree onto a sibling. Bind, then unbind-all,
|
|
1113
|
+
// then bind again: a user config that left the prefix table empty makes
|
|
1114
|
+
// `unbind-key -a -T prefix` fail and abort the rest of this chain.
|
|
1115
|
+
// BEFORE remain-on-exit, which stays last because an old remote tmux
|
|
1116
|
+
// rejects `failed` and aborts the rest of the chain.
|
|
1117
|
+
...nestedPrefixTableResetCommands(),
|
|
1091
1118
|
// #210: keep a CRASHED pane so the failure is still on screen. Without this,
|
|
1092
1119
|
// tmux destroys the pane -> window -> session (and, being the only session,
|
|
1093
1120
|
// the whole remote server) the instant the pane command exits, which tears the
|
|
@@ -1104,7 +1131,8 @@ export function buildRemoteLaunchCommand(options) {
|
|
|
1104
1131
|
// LAST in the chain on purpose: tmux aborts the remaining commands of a `\;`
|
|
1105
1132
|
// sequence once one errors (also verified), and `failed` needs tmux >= 3.2 on
|
|
1106
1133
|
// the REMOTE host. Trailing, a rejection costs only this option; leading, it
|
|
1107
|
-
// would silently drop status/mouse/prefix/escape-time/window-size
|
|
1134
|
+
// would silently drop status/mouse/prefix/escape-time/window-size and the
|
|
1135
|
+
// prefix-table reduction with it.
|
|
1108
1136
|
`set -t ${remoteName} remain-on-exit failed`,
|
|
1109
1137
|
].join(' \\; ');
|
|
1110
1138
|
// ssh runs its trailing args through the remote login shell, so the entire
|
|
@@ -1116,7 +1144,14 @@ export function buildRemoteLaunchCommand(options) {
|
|
|
1116
1144
|
// `ssh -o BatchMode=yes` (preserving the historical token order), then the rest
|
|
1117
1145
|
// of the connection args, then the target and the quoted tmux invocation.
|
|
1118
1146
|
const [ssh, batchMode, ...connectionArgs] = buildSshConnectionArgs(remote);
|
|
1119
|
-
const sshParts = [
|
|
1147
|
+
const sshParts = [
|
|
1148
|
+
ssh,
|
|
1149
|
+
batchMode,
|
|
1150
|
+
'-t',
|
|
1151
|
+
...connectionArgs,
|
|
1152
|
+
remoteSshTarget(remote),
|
|
1153
|
+
shellescape(withRemoteTmuxPath(tmuxInvocation)),
|
|
1154
|
+
];
|
|
1120
1155
|
return sshParts.join(' ');
|
|
1121
1156
|
}
|
|
1122
1157
|
/**
|
|
@@ -1132,7 +1167,7 @@ export function buildRemoteKillCommand(options) {
|
|
|
1132
1167
|
const remoteName = remoteTmuxSessionName(sessionId);
|
|
1133
1168
|
const killCmd = `tmux -L ${REMOTE_TMUX_SOCKET} kill-session -t ${shellescape(remoteName)}`;
|
|
1134
1169
|
const [ssh, ...connectionArgs] = buildSshConnectionArgs(remote);
|
|
1135
|
-
return [ssh, ...connectionArgs, remoteSshTarget(remote), shellescape(killCmd)].join(' ');
|
|
1170
|
+
return [ssh, ...connectionArgs, remoteSshTarget(remote), shellescape(withRemoteTmuxPath(killCmd))].join(' ');
|
|
1136
1171
|
}
|
|
1137
1172
|
// ========== Docker cases (COD-Docker) ==========
|
|
1138
1173
|
//
|
|
@@ -1248,8 +1283,12 @@ export function buildDockerLaunchCommand(opts) {
|
|
|
1248
1283
|
`new-session -A -s ${dkrName} -c ${workdir} ${shellescape(paneCommand)}`,
|
|
1249
1284
|
`set -t ${dkrName} status off`,
|
|
1250
1285
|
`set -t ${dkrName} mouse off`,
|
|
1251
|
-
`set -t ${dkrName} prefix
|
|
1286
|
+
`set -t ${dkrName} prefix ${NESTED_TMUX_PREFIX}`,
|
|
1252
1287
|
'set -s escape-time 0',
|
|
1288
|
+
// Same reduction as the owned-remote chain: the in-container server is
|
|
1289
|
+
// Codeman's (`-L codeman-docker`), and its stock prefix table would move
|
|
1290
|
+
// the inner client to a sibling session on Ctrl+Q then )/(/s/w/L.
|
|
1291
|
+
...nestedPrefixTableResetCommands(),
|
|
1253
1292
|
].join(' \\; ');
|
|
1254
1293
|
const execEnvFlags = [];
|
|
1255
1294
|
for (const [k, v] of Object.entries(execEnv))
|
|
@@ -1459,7 +1498,14 @@ export function resolveDockerLaunchOptions(mode, docker, sessionId, resumeSessio
|
|
|
1459
1498
|
export function buildRemoteAttachCommand(remote, remoteSessionName) {
|
|
1460
1499
|
const tmuxInvocation = `tmux -L codeman attach -t ${shellescape(remoteSessionName)}`;
|
|
1461
1500
|
const [ssh, batchMode, ...connectionArgs] = buildSshConnectionArgs(remote);
|
|
1462
|
-
const sshParts = [
|
|
1501
|
+
const sshParts = [
|
|
1502
|
+
ssh,
|
|
1503
|
+
batchMode,
|
|
1504
|
+
'-t',
|
|
1505
|
+
...connectionArgs,
|
|
1506
|
+
remoteSshTarget(remote),
|
|
1507
|
+
shellescape(withRemoteTmuxPath(tmuxInvocation)),
|
|
1508
|
+
];
|
|
1463
1509
|
return sshParts.join(' ');
|
|
1464
1510
|
}
|
|
1465
1511
|
/**
|
|
@@ -3428,7 +3474,9 @@ export class TmuxManager extends EventEmitter {
|
|
|
3428
3474
|
* - `Enter` key is sent as a SEPARATE tmux invocation after a small delay
|
|
3429
3475
|
* - Ink (Claude CLI) needs text and Enter split to avoid treating Enter as a newline
|
|
3430
3476
|
*/
|
|
3431
|
-
async sendInput(sessionId, input) {
|
|
3477
|
+
async sendInput(sessionId, input, options) {
|
|
3478
|
+
if (options?.beforeDispatch && input !== '\r')
|
|
3479
|
+
return false;
|
|
3432
3480
|
const session = this.sessions.get(sessionId);
|
|
3433
3481
|
if (!session) {
|
|
3434
3482
|
console.error(`[TmuxManager] sendInput failed: no session found for ${sessionId}. Known: ${Array.from(this.sessions.keys()).join(', ')}`);
|
|
@@ -3438,7 +3486,7 @@ export class TmuxManager extends EventEmitter {
|
|
|
3438
3486
|
// inputRunner() so a test subclass can record what WOULD reach tmux.
|
|
3439
3487
|
const run = this.inputRunner();
|
|
3440
3488
|
if (!run) {
|
|
3441
|
-
return true;
|
|
3489
|
+
return options?.beforeDispatch?.() ?? true;
|
|
3442
3490
|
}
|
|
3443
3491
|
console.log(`[TmuxManager] sendInput to ${session.muxName}, input length: ${input.length}, hasCarriageReturn: ${input.includes('\r')}`);
|
|
3444
3492
|
if (!isValidMuxName(session.muxName)) {
|
|
@@ -3465,7 +3513,7 @@ export class TmuxManager extends EventEmitter {
|
|
|
3465
3513
|
// selection dialog ignores a pasted `3` and Enter then confirms the
|
|
3466
3514
|
// highlighted option (see submitsAsKeys).
|
|
3467
3515
|
if (submitsAsKeys(textPart)) {
|
|
3468
|
-
await run(`${this.tmux()} send-keys -t "${session.muxName}" -l ${shellescape(escapeTmuxTrailingSemicolon(textPart))}`);
|
|
3516
|
+
await run(`${this.tmux()} send-keys -t "${session.muxName}" -l -- ${shellescape(escapeTmuxTrailingSemicolon(textPart))}`);
|
|
3469
3517
|
}
|
|
3470
3518
|
else {
|
|
3471
3519
|
await pasteText(run, buildPasteTextCommands(this.tmux(), session.muxName, textPart));
|
|
@@ -3483,10 +3531,12 @@ export class TmuxManager extends EventEmitter {
|
|
|
3483
3531
|
}
|
|
3484
3532
|
else if (textPart) {
|
|
3485
3533
|
// Text only, no Enter
|
|
3486
|
-
await run(`${this.tmux()} send-keys -t "${session.muxName}" -l ${shellescape(escapeTmuxTrailingSemicolon(textPart))}`);
|
|
3534
|
+
await run(`${this.tmux()} send-keys -t "${session.muxName}" -l -- ${shellescape(escapeTmuxTrailingSemicolon(textPart))}`);
|
|
3487
3535
|
}
|
|
3488
3536
|
else if (hasCarriageReturn) {
|
|
3489
|
-
// Enter only
|
|
3537
|
+
// Enter only: no await between the guard and dispatch.
|
|
3538
|
+
if (options?.beforeDispatch && !options.beforeDispatch())
|
|
3539
|
+
return false;
|
|
3490
3540
|
await run(`${this.tmux()} send-keys -t "${session.muxName}" Enter`);
|
|
3491
3541
|
}
|
|
3492
3542
|
return true;
|
|
@@ -3627,7 +3677,7 @@ export class TmuxManager extends EventEmitter {
|
|
|
3627
3677
|
const hasCarriageReturn = input.includes('\r');
|
|
3628
3678
|
const textPart = input.replace(/\r/g, '').replace(/\n/g, '').trimEnd();
|
|
3629
3679
|
if (textPart && hasCarriageReturn) {
|
|
3630
|
-
execSync(`${tmux} send-keys -t ${shellescape(target)} -l ${shellescape(escapeTmuxTrailingSemicolon(textPart))}`, {
|
|
3680
|
+
execSync(`${tmux} send-keys -t ${shellescape(target)} -l -- ${shellescape(escapeTmuxTrailingSemicolon(textPart))}`, {
|
|
3631
3681
|
encoding: 'utf-8',
|
|
3632
3682
|
timeout: EXEC_TIMEOUT_MS,
|
|
3633
3683
|
});
|
|
@@ -3637,7 +3687,7 @@ export class TmuxManager extends EventEmitter {
|
|
|
3637
3687
|
});
|
|
3638
3688
|
}
|
|
3639
3689
|
else if (textPart) {
|
|
3640
|
-
execSync(`${tmux} send-keys -t ${shellescape(target)} -l ${shellescape(escapeTmuxTrailingSemicolon(textPart))}`, {
|
|
3690
|
+
execSync(`${tmux} send-keys -t ${shellescape(target)} -l -- ${shellescape(escapeTmuxTrailingSemicolon(textPart))}`, {
|
|
3641
3691
|
encoding: 'utf-8',
|
|
3642
3692
|
timeout: EXEC_TIMEOUT_MS,
|
|
3643
3693
|
});
|
|
@@ -3703,7 +3753,8 @@ export class TmuxManager extends EventEmitter {
|
|
|
3703
3753
|
}
|
|
3704
3754
|
}
|
|
3705
3755
|
capturePaneBuffer(muxName, paneTarget, opts) {
|
|
3706
|
-
|
|
3756
|
+
const exec = this.captureRunner();
|
|
3757
|
+
if (!exec)
|
|
3707
3758
|
return '';
|
|
3708
3759
|
const target = resolveTmuxPaneTarget(muxName, paneTarget);
|
|
3709
3760
|
if (!target) {
|
|
@@ -3739,12 +3790,31 @@ export class TmuxManager extends EventEmitter {
|
|
|
3739
3790
|
execOpts.maxBuffer =
|
|
3740
3791
|
(opts?.maxCaptureBytes ?? DEFAULT_TERMINAL_BUFFER_MAX_BYTES) + FULL_HISTORY_CAPTURE_SLACK_BYTES;
|
|
3741
3792
|
}
|
|
3742
|
-
const
|
|
3793
|
+
const cursorQuery = `display-message -p -t ${shellescape(target)} '#{cursor_x} #{cursor_y} #{pane_width} #{pane_height} #{history_size} #{alternate_on}'`;
|
|
3794
|
+
const captureCommand = `${this.tmux()} ${captureFlags} -t ${shellescape(target)}`;
|
|
3795
|
+
// The visible frame and its caret come from ONE tmux invocation
|
|
3796
|
+
// (the capture, `\;`, then the cursor query): tmux runs a command list back to back
|
|
3797
|
+
// in its command queue, with no pane output parsed between the two, so the
|
|
3798
|
+
// caret belongs to the frame. Two separate calls raced the CLI's repaint: a
|
|
3799
|
+
// CLI that redraws its composer a few ms after input arrives (codex) could be
|
|
3800
|
+
// captured before the redraw and its caret queried after it, and guarded
|
|
3801
|
+
// stage then refused a frame the keys had already reached. Only output that
|
|
3802
|
+
// splitFrameAndCursor() cannot split (a last line that is not the query's)
|
|
3803
|
+
// falls back to the two separate calls, which is what this always did. A call
|
|
3804
|
+
// that THREW (a hung tmux timing out) goes to the catch below like any other
|
|
3805
|
+
// capture failure: retrying it would block the event loop for a second timeout
|
|
3806
|
+
// on every `GET .../terminal` load.
|
|
3807
|
+
const combined = fullHistory
|
|
3808
|
+
? null
|
|
3809
|
+
: splitFrameAndCursor(exec(`${captureCommand} \\; ${cursorQuery}`, { encoding: 'utf-8', timeout: EXEC_TIMEOUT_MS }));
|
|
3810
|
+
const rawCapture = joinScrollbackAndFrame(scrollbackOverride, combined?.frame ?? exec(captureCommand, execOpts), scrollbackOverride !== undefined ? opts?.scrollbackOverrideScreen : undefined);
|
|
3743
3811
|
// Query the cursor BEFORE deciding anything else. On the full-history path
|
|
3744
3812
|
// it settles both how the capture is trimmed and whether a cursor move is
|
|
3745
3813
|
// appended, and those two have to agree: trailing blank rows are only safe
|
|
3746
3814
|
// to keep when a move follows to put the caret back above them.
|
|
3747
|
-
const geometry = queryPaneCursor(() =>
|
|
3815
|
+
const geometry = queryPaneCursor(() => combined
|
|
3816
|
+
? combined.cursor
|
|
3817
|
+
: exec(`${this.tmux()} ${cursorQuery}`, { encoding: 'utf-8', timeout: EXEC_TIMEOUT_MS }));
|
|
3748
3818
|
// Report the size the pane was really drawing at. The visible-frame path
|
|
3749
3819
|
// below addresses every row absolutely, so a consumer whose terminal is
|
|
3750
3820
|
// shorter than this piles the overflow rows onto its last line and loses
|
|
@@ -3813,6 +3883,16 @@ export class TmuxManager extends EventEmitter {
|
|
|
3813
3883
|
return null;
|
|
3814
3884
|
}
|
|
3815
3885
|
}
|
|
3886
|
+
/**
|
|
3887
|
+
* How {@link capturePaneBuffer} runs tmux, or null where it must not (vitest).
|
|
3888
|
+
* Split out like {@link inputRunner} so a test subclass can count and script the
|
|
3889
|
+
* calls a capture makes.
|
|
3890
|
+
*/
|
|
3891
|
+
captureRunner() {
|
|
3892
|
+
if (IS_TEST_MODE)
|
|
3893
|
+
return null;
|
|
3894
|
+
return (cmd, opts) => execSync(cmd, opts);
|
|
3895
|
+
}
|
|
3816
3896
|
/**
|
|
3817
3897
|
* Capture the active pane for a tmux session.
|
|
3818
3898
|
*
|