Skip to content

feat(opencode): resolve @-tags from external editor output#26400

Open
arafays wants to merge 2 commits intoanomalyco:devfrom
arafays:feat/editor-tag-resolver
Open

feat(opencode): resolve @-tags from external editor output#26400
arafays wants to merge 2 commits intoanomalyco:devfrom
arafays:feat/editor-tag-resolver

Conversation

@arafays
Copy link
Copy Markdown

@arafays arafays commented May 8, 2026

Issue for this PR

Closes #26252

Type of change

  • New feature

What does this PR do?

When the user opens the external editor (prefix+e), writes @filename references, and saves, those references stay as plain text. This adds a resolution step: after the editor returns, the content is scanned for @src/filename patterns via FILE_REGEX, and unknown tags are resolved through an interactive dialog (one at a time) with live file search.

How did you verify your code works?

by running actual prompts screenshot
start local server with my edits
image

write prompt in editor
@explore what the @prompt does and and how its used in @dialog-editor
Screenshot from 2026-05-08 23-59-45

shows dialog recognizes that the first @mention is agent and starts with second unresolved
Screenshot from 2026-05-09 00-01-06

image

itterates through all mentions that arent recognized
image

final prompt before submit
image

after submit prompt correctly recognizes @agent directory selected from dialog also the file selected from second resolved
image

Screenshots / recordings

If this is a UI change, please include a screenshot or recording.

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

@github-actions github-actions Bot added needs:compliance This means the issue will auto-close after 2 hours. and removed needs:compliance This means the issue will auto-close after 2 hours. labels May 8, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 8, 2026

Thanks for updating your PR! It now meets our contributing guidelines. 👍

@arafays arafays force-pushed the feat/editor-tag-resolver branch from 8094f44 to 8e693e9 Compare May 8, 2026 19:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE]: support resolving @filename tags from external editor output

1 participant