desktop: "Open in <Editor>" menu in Review Pane opens workspace root directory instead of active file tab

已关闭 适合新手
#62,040 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

@ElonYangDev 已经在做这个了。

开始于 2026年11月5日。

  • #62056 来自 @ElonYangDev —— 未关闭

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
82/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
typescript

调研方向

找到 Review Pane 的标题组件,并追踪“Open in...”操作处理程序,以及活动标签页如何提供其文件路径。检查处理程序如何将目标传递给 openInApp;完成标准是选择编辑器会打开活动文件,并且在没有活动文件标签页时使用工作区目录。

由索引模型根据 Issue 内容生成。

描述

pending close triaging

Summary

In the OpenCode Desktop Review / Workspace pane header, selecting an external editor (e.g., Sublime Text, Antigravity, Finder) from the top-right "Open in..." dropdown opens the workspace root directory instead of the currently active file tab displayed in the pane.

Environment

  • opencode version: 2.2.5
  • OS: Darwin 27.0.0 (macOS / darwin arm64)
  • Terminal: Desktop App (Review Pane)
  • Shell: /bin/zsh
  • Install/channel: Desktop 2.2.5
  • Active plugins: None

Reproduction

  1. Open a workspace in OpenCode Desktop.
  2. Open a specific file tab in the Review pane (e.g., queries/check_all_reg_properties.sql).
  3. Click the top-right "Open in..." dropdown menu located beside the active tab bar.
  4. Select an external editor (e.g., "Sublime Text").

Expected Behavior

The selected editor opens the active file tab (/path/to/workspace/queries/check_all_reg_properties.sql).

Actual Behavior

The editor opens the entire workspace root folder (/path/to/workspace/) instead of the specific file tab being viewed.

Suggested Fix

Update the action handler in the Review Pane header component to prioritize the active tab file path:

const targetPath = activeTab?.filePath ?? workspace.directory;
openInApp(selectedApp, targetPath);
主要语言
TypeScript
星标
224k
派生
30k
平均合并
5 小时 25 分钟
30 天内合并 PR
494

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

anomalyco/opencode 的其他 Issue

查看 anomalyco/opencode 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。