Skip to content

feat: add plugin file-change notifications#26121

Open
Zireael wants to merge 1 commit intoanomalyco:devfrom
Zireael:qg-198-filewatch-hook
Open

feat: add plugin file-change notifications#26121
Zireael wants to merge 1 commit intoanomalyco:devfrom
Zireael:qg-198-filewatch-hook

Conversation

@Zireael
Copy link
Copy Markdown

@Zireael Zireael commented May 7, 2026

Issue for this PR

Closes #26118

Type of change

  • New feature
  • Bug fix
  • Refactor / code improvement
  • Documentation

What does this PR do?

This is the file-watcher half of the plugin post-edit parity work, paired with #14228.

It adds notifyFileChanged({ filePath, event }) to @opencode-ai/plugin tool context so plugin-authored tools can tell OpenCode when they have written a file. The host registry turns that into the same file and file-watcher bus events that native write/edit tools already emit.

This PR does not try to expose LSP itself; that remains covered by #14228.

How did you verify your code works?

  • bun test test/tool/registry.test.ts

Screenshots / recordings

N/A

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 7, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 7, 2026

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

@Zireael Zireael marked this pull request as ready for review May 7, 2026 05:07
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]: expose a plugin-safe file refresh hook for edits

1 participant