- runner/terminal.ts: TerminalFeed polls the pane (capture-pane -e, one loop per runner shared by viewers), sends changed lines, scrolled-off lines and the cursor; terminalInput (send-keys -H / paste-buffer -p) with access, liveness, size and rate checks, resets auto_nudges, logs terminal_input; terminalSse with 15 s pings for Cloudflare - web: GET/POST /api/runners/[id]/terminal, RunnerTerminal (xterm.js) in the runner panel and on the story page; help - testkit: terminal.test.ts — real tmux into a headless xterm, history, input, access, limits, SSE - OpenSpec change archived; new spec runner-terminal Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
15 lines
1.2 KiB
Markdown
15 lines
1.2 KiB
Markdown
# Tasks: PEP-9
|
||
|
||
## 1. Runner
|
||
- [x] 1.1 tmux: `paneInfo` (курсор, размер, history_size), `capturePaneAnsi`, `sendHex`
|
||
- [x] 1.2 `terminal.ts`: `TerminalFeed` (опрос, кадры, история, общий на раннер), `normalizeAnsiLines`, `terminalInput` (проверки, лимиты, сброс автопродолжений, журнал)
|
||
|
||
## 2. Веб
|
||
- [x] 2.1 `GET/POST /api/runners/[id]/terminal`: доступ, SSE с пингом, ввод с лимитами
|
||
- [x] 2.2 `RunnerTerminal` на xterm.js: просмотр/ввод, вставка, A−/A+, полноэкранный, переподключение, статус
|
||
- [x] 2.3 Панель раннера и страница стори (активная сессия); «Помощь»
|
||
|
||
## 3. Проверка
|
||
- [x] 3.1 e2e в testkit: кадр и изменения из настоящего tmux, история, ввод (буквы, Enter, вставка), запрет чужому и в завершённую сессию, лимиты, сброс автопродолжений и журнал, SSE route
|
||
- [x] 3.2 Свой `next dev` против копии базы: терминал в панели раннера
|