feat(extensions): add OpenCode workspace references - #1940
Merged
limityan merged 1 commit intoJul 31, 2026
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
摘要
references/旧reference的 path、description、hidden,并保持确定性的 alias 覆盖语义。@目录选择器,形成单一 native-first 有效目录快照;原生关联目录继续由 Workspace owner 管理,外部声明只读展示。设计取舍
e4bd9757固定:OPENCODE_CONFIG_DIR替换默认全局根,随后依次应用 project direct root-to-nearest 与 project.opencoderoot-to-nearest;高优先级无效/Git entry 不回退到低优先级同 alias。WorkspaceInfo.related_paths始终在外部引用之前;不同 alias 即使指向同一路径也保留,因为 alias 是用户可见身份。DiscoverOnly可发现但不进入有效目录;仅Auto/AskBeforeUse能投影到消费点。安全与范围
workspaceId与注册根绑定;worktree 例外由服务端实时解析 live Git repository identity,缓存中的 stale/prunable 路径不能授权扫描。NotFound当作缺失,权限/其他 metadata 错误按 transient 处理并保留 last-valid。验证
cargo check --workspacepnpm run type-check:web;前端聚焦测试:26/26pnpm run i18n:auditgit diff --check规模:单一 commit,44 files,
+3314/-86。