2026-05-19 01:58:48 +08:00
|
|
|
# auto-tmux
|
|
|
|
|
|
|
|
|
|
`auto-tmux` 是 tmux 自动化操控技能,用于读取 pane 输出、发送按键、批量巡检、救援卡住的终端,以及组织多 AI 终端协作。
|
|
|
|
|
|
|
|
|
|
## 入口
|
|
|
|
|
|
|
|
|
|
- [SKILL.md](./SKILL.md) - 技能触发条件、命令片段、规则和质量门禁。
|
2026-05-19 02:12:30 +08:00
|
|
|
- [scripts/](./scripts/) - 安全封装的 tmux 自动化脚本。
|
2026-05-19 01:58:48 +08:00
|
|
|
- [references/](./references/) - tmux / oh-my-tmux 参考、示例和故障排查。
|
|
|
|
|
- [assets/](./assets/) - 指向仓库外部 submodule 的只读软链接入口。
|
|
|
|
|
|
|
|
|
|
## 资产来源
|
|
|
|
|
|
|
|
|
|
| 入口 | 指向 | 用途 |
|
|
|
|
|
|:---|:---|:---|
|
|
|
|
|
| `assets/oh-my-tmux` | `tools/external/.tmux` | gpakosz/oh-my-tmux 配置参考 |
|
|
|
|
|
| `assets/tmux-src` | `tools/external/tmux` | tmux 上游源码参考 |
|
|
|
|
|
|
|
|
|
|
## 快速验证
|
|
|
|
|
|
|
|
|
|
```bash
|
2026-05-19 02:12:30 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/auto-tmux.sh
|
2026-05-19 02:30:58 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/swarm-state.sh
|
2026-05-19 02:49:16 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/swarm-brief.sh
|
2026-05-19 03:05:45 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/swarm-watch.sh
|
2026-05-19 03:48:40 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/swarm-archive.sh
|
2026-05-19 03:58:32 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/swarm-board.sh
|
2026-05-19 13:16:03 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/swarm-deps-graph.sh
|
2026-05-19 13:21:24 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/swarm-export.sh
|
2026-05-19 13:30:56 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/swarm-timeline.sh
|
2026-05-19 13:39:16 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/swarm-blockers.sh
|
2026-05-19 14:06:18 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/swarm-results.sh
|
2026-05-19 13:43:58 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/swarm-report-pack.sh
|
2026-05-19 04:04:40 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/swarm-assign.sh
|
2026-05-19 04:12:53 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/swarm-health.sh
|
2026-05-19 13:49:57 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/remote-readonly.sh
|
2026-05-19 04:08:21 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/record-summary.sh
|
2026-05-19 14:15:08 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/check-jsonl.sh
|
2026-05-19 14:22:42 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/review-checklist.sh
|
2026-05-19 14:30:59 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/verify-report-pack.sh
|
2026-05-19 04:16:06 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/completion.bash
|
2026-05-19 03:54:25 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/safety-check.sh
|
2026-05-19 02:37:16 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/render-swarm-prompt.sh
|
2026-05-19 02:59:49 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/swarm-dispatch.sh
|
2026-05-19 02:55:13 +08:00
|
|
|
bash -n skills/auto-tmux/scripts/validate-auto-tmux.sh
|
2026-05-19 02:12:30 +08:00
|
|
|
skills/auto-tmux/scripts/auto-tmux.sh help
|
2026-05-19 02:30:58 +08:00
|
|
|
skills/auto-tmux/scripts/swarm-state.sh help
|
2026-05-19 02:49:16 +08:00
|
|
|
skills/auto-tmux/scripts/swarm-brief.sh --help
|
2026-05-19 03:54:25 +08:00
|
|
|
skills/auto-tmux/scripts/safety-check.sh --text "make test"
|
2026-05-19 02:37:16 +08:00
|
|
|
skills/auto-tmux/scripts/render-swarm-prompt.sh commander --session ai-hub --task "smoke"
|
2026-05-19 02:30:58 +08:00
|
|
|
skills/auto-tmux/scripts/auto-tmux-smoke-test.sh
|
2026-05-19 02:55:13 +08:00
|
|
|
skills/auto-tmux/scripts/validate-auto-tmux.sh
|
2026-05-19 01:58:48 +08:00
|
|
|
skills/auto-skill/scripts/validate-skill.sh skills/auto-tmux --strict
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
## 使用边界
|
|
|
|
|
|
2026-05-19 02:12:30 +08:00
|
|
|
- 优先使用 `scripts/auto-tmux.sh`,需要低层调试时再直接使用 tmux 原生命令。
|
|
|
|
|
- 发送按键前必须先 `capture-pane` 复核目标上下文;脚本会默认打印最近上下文。
|
2026-05-19 03:54:25 +08:00
|
|
|
- 发送长文本、粘贴文件或下发 prompt 前先运行 `scripts/safety-check.sh`。
|
2026-05-19 13:52:15 +08:00
|
|
|
- SSH/远程场景默认只读,先用 `scripts/remote-readonly.sh` 采集证据,再按 `references/session-safety.md` 判断是否需要人工确认升级。
|
2026-05-19 01:58:48 +08:00
|
|
|
- 批量操作前必须先列出 session/window/pane 白名单。
|
2026-05-19 02:30:58 +08:00
|
|
|
- 多 worker 并发前用 `swarm-state.sh` 管理任务、锁和状态,避免重复修改同一资源。
|
2026-05-19 01:58:48 +08:00
|
|
|
- 不在未知 pane 中发送破坏性命令。
|
|
|
|
|
- 不在本目录复制或修改上游 tmux / oh-my-tmux 源码。
|