tui: add shortcut to copy last AI response to clipboard
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 65/100
- Issue 类型
- 功能
- 描述清晰度
- 基本清楚
- 活跃度
- 活跃
- 技术栈
- typescript
- 领域
- cli
调研方向
首先找到 TUI 中 messages.copy 和 session.copy 的按键绑定定义,然后追踪每个命令如何访问并复制消息内容。添加一个专用快捷键,仅用于选择最后一条 AI 回复,并验证它会将该回复写入系统剪贴板。完成标准是:新快捷键的运行不依赖消息光标,并且不会复制整个会话。
由索引模型根据 Issue 内容生成。
描述
Summary
Add a dedicated keyboard shortcut to copy the last AI response to the system clipboard, eliminating the need to manually select text with the mouse. Currently messages.copy (<leader>y) copies the message under the cursor, and session.copy copies the entire session — neither provides quick access to just the final answer.
Environment
- opencode version: 2.0.32
- OS: Darwin 22.6.0 (Darwin Kernel Version 22.6.0: Tue Jul 15 08:22:28 PDT 2025; root:xnu-8796.141.3.713.2~2/RELEASE_X86_64 x86_64)
- Terminal: WarpTerminal (TERM=xterm-256color, COLORTERM=truecolor)
- Shell: /bin/zsh
- Install/channel: latest
- Active plugins: warp-notify
User Context
User analyzes data in OpenCode and pastes results into another AI for review. Currently they must select the final AI response text with the mouse to copy it. A dedicated shortcut for "copy last AI response" would streamline this workflow significantly.
Expected Behavior
A keyboard shortcut (e.g., ctrl+shift+y or similar) that copies only the last AI response to the system clipboard.
Actual Behavior
No dedicated shortcut exists. messages.copy (<leader>y) copies the message under the cursor, not specifically the last AI response. session.copy copies the entire session transcript, which is excessive when only the final answer is needed.
Additional Context
<leader>y(messages.copy) — copies message under cursor, not last AI response<leader>x(session.export) — exports to editor, doesn't copy to clipboardsession.copy(unbound by default) — copies entire session, too broad
- 主要语言
- TypeScript
- 星标
- 215k
- 派生
- 28.9k
- 平均合并
- 11 小时 19 分钟
- 30 天内合并 PR
- 320
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
anomalyco/opencode 的其他 Issue
-
pending close triaging
难度 2/5 1-3 小时 新手友好度 72/100
anomalyco/opencode#57209 · 1 条评论 ·
维护者通常 1 天内回复
-
reproduced
难度 2/5 1-3 小时 新手友好度 78/100
anomalyco/opencode#57127 · 2 条评论 ·
维护者通常 1 天内回复
-
pending close triaging
难度 2/5 1-3 小时 新手友好度 66/100
anomalyco/opencode#57070 · 1 条评论 ·
维护者通常 1 天内回复
-
Plan mode leave reminder becomes the final user turn after a tool-driven agent switch, models refuse可能已有人在做 @Veld101 于 1 天前认领。 未关闭reproduced
难度 2/5 1-3 小时 新手友好度 72/100
anomalyco/opencode#57013 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 64/100
anomalyco/opencode#56891 · 2 条评论 ·
维护者通常 1 天内回复
查看 anomalyco/opencode 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
bug
难度 2/5 1-3 小时 新手友好度 84/100
维护者通常 1 天内回复
-
bug
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 67/100
mobile-next/mobile-mcp#526 ·
维护者通常 1 天内回复
-
e2e-failure ready-to-code
难度 1/5 1 小时以内 新手友好度 73/100
redhat-developer/rhdh-plugin-export-overlays#4470 · 1 条评论 ·
维护者通常 1 天内回复