[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-81443":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":13,"openIssues":14,"contributorsCount":14,"subscribersCount":14,"size":14,"stars1d":13,"stars7d":15,"stars30d":15,"stars90d":14,"forks30d":14,"starsTrendScore":16,"compositeScore":17,"rankGlobal":10,"rankLanguage":10,"license":10,"archived":18,"fork":18,"defaultBranch":19,"hasWiki":20,"hasPages":18,"topics":21,"createdAt":10,"pushedAt":10,"updatedAt":22,"readmeContent":23,"aiSummary":24,"trendingCount":14,"starSnapshotCount":14,"syncStatus":15,"lastSyncTime":25,"discoverSource":26},81443,"pi-live-terminal","tanishqkancharla\u002Fpi-live-terminal","tanishqkancharla","Pi extension that adds a run_live_terminal tool and a live tmux widget inside Pi.","",null,"TypeScript",34,1,0,2,3,0.9,false,"main",true,[],"2026-06-12 02:04:15","\u003Cimg width=\"1680\" height=\"720\" alt=\"tanishqk_Overhead_aerial_view_of_New_York_City_at_golden_hour_650bc1e7-22f5-4e28-9576-ceaa73ed132c_0\" src=\"https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002F219e4167-d04f-4c8a-9373-bdf3a6e96856\" \u002F>\n\n# pi-live-terminal\n\nPi extension that adds `live_terminal_run` and `live_terminal_close` tools plus a live tmux widget inside Pi.\n\nhttps:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002Fb4ec6d34-fd8a-4254-bf74-e216779649f6\n\n## What it does\n\n- Starts long-running or interactive commands in detached tmux sessions.\n- Can attach to an existing tmux session by calling `live_terminal_run` without a command and passing `session_name` or `target`.\n- Can wait for terminal output or lifecycle events with `live_terminal_run({ wait_for: ... })`.\n- Closes the live pane and kills the attached tmux session with `live_terminal_close`.\n- Shows live terminal output in a Pi widget above the editor.\n- Streams pane output via `tmux pipe-pane` for event-driven updates (no capture polling loop for output).\n- Reports completed processes to the human and agent with the exit status code.\n- Reattaches the widget when a Pi session restarts and the tmux session still exists.\n- Adds `\u002Flive-terminal:run`, `\u002Flive-terminal:attach`, `\u002Flive-terminal:focus`, and `\u002Flive-terminal:close` commands.\n- Adds shortcuts:\n  - `ctrl+shift+f` — focus the tmux session in a full-screen interactive modal; press it again to close the modal\n  - `ctrl+shift+x` — detach and kill the tmux session\n  - `ctrl+shift+v` — detach without killing the tmux session; after completion, close the widget\n\n## Waiting from `live_terminal_run`\n\n`live_terminal_run` returns immediately by default. Pass `wait_for` to block the tool call until a condition matches or times out:\n\n```ts\nlive_terminal_run({\n  command: \"npm run dev\",\n  wait_for: { regex: \"Local:|ready\", timeout_ms: 60000 }\n})\n```\n\n`wait_for.regex` is a JavaScript regular expression source matched against captured tmux pane output. It uses multiline matching by default, and `ignore_case: true` adds case-insensitive matching.\n\nSupported events:\n\n- `exit` — waits until a command started by `live_terminal_run` records its exit status.\n- `target_closed` — waits until the attached tmux pane\u002Fsession no longer exists.\n\nDefaults: `timeout_ms: 30000`, `poll_ms: 500`.\n\n## Install\n\n```sh\npi install npm:pi-live-terminal\n```\n\nRestart Pi after installing or updating the extension.\n\n## Requirements\n\n- [tmux](https:\u002F\u002Fgithub.com\u002Ftmux\u002Ftmux)\n- Pi coding agent extension runtime\n","pi-live-terminal 是一个为 Pi 编程环境扩展的工具，它增加了 `live_terminal_run` 和 `live_terminal_close` 功能以及一个实时 tmux 小部件。项目采用 TypeScript 开发，允许用户在分离的 tmux 会话中启动长时间运行或交互式的命令，并能在 Pi 界面上方显示实时终端输出。通过 `tmux pipe-pane` 技术实现事件驱动的更新机制，无需轮询即可获取最新输出。此工具还支持等待特定输出或生命周期事件后继续执行后续操作，适用于需要持续监控后台任务状态、进行开发调试或希望直接从编辑器界面管理 tmux 会话的各种场景。","2026-06-11 04:05:03","CREATED_QUERY"]