Skip to content
This repository was archived by the owner on May 20, 2026. It is now read-only.

feat: wire plugins through CopilotCLI customization provider#4962

Merged
joshspicer merged 3 commits into
mainfrom
josh/plugins-chatpromptfiles-api
Apr 3, 2026
Merged

feat: wire plugins through CopilotCLI customization provider#4962
joshspicer merged 3 commits into
mainfrom
josh/plugins-chatpromptfiles-api

Conversation

@joshspicer
Copy link
Copy Markdown
Member

@joshspicer joshspicer commented Apr 3, 2026

Consume the new chat.plugins API and plumb it through to the CopilotCLI customization provider.

Changes

  • Mirror updated chatPromptFiles d.ts
  • Add plugins/onDidChangePlugins to IChatPromptFileService interface
  • Wire vscode.chat.plugins in ChatPromptFileService implementation
  • Add Plugins to CopilotCLI provider supportedTypes (unhides Plugins section)
  • Add getPluginItems() — derives name from basename(uri)
  • Subscribe to onDidChangePlugins for provider invalidation
  • Fix all test mocks + add plugin tests

Depends on: microsoft/vscode#307669

Copilot AI review requested due to automatic review settings April 3, 2026 16:52
@joshspicer joshspicer marked this pull request as draft April 3, 2026 16:54
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adopts the proposed vscode.chat.plugins API and plumbs plugin resources through the extension’s prompt-file abstraction so the Copilot CLI customization provider can surface “Plugins” in the chat customization UI.

Changes:

  • Add ChatPluginResource plus chat.plugins / chat.onDidChangePlugins to the local proposed chatPromptFiles API typings.
  • Extend IChatPromptFileService and its VS Code-backed implementation to expose plugins and onDidChangePlugins.
  • Update the Copilot CLI customization provider to support and return plugin customization items, including test/mock updates and new plugin-focused unit tests.

Reviewed changes

Copilot reviewed 7 out of 8 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/extension/vscode.proposed.chatPromptFiles.d.ts Adds ChatPluginResource and exposes chat.plugins + chat.onDidChangePlugins in the proposed API typings.
src/extension/chatSessions/common/chatPromptFileService.ts Extends IChatPromptFileService with plugins and onDidChangePlugins.
src/extension/chatSessions/vscode-node/chatPromptFileService.ts Wires vscode.chat.plugins and vscode.chat.onDidChangePlugins through the service implementation.
src/extension/chatSessions/vscode-node/copilotCLICustomizationProvider.ts Adds Plugins to supportedTypes, emits invalidation on plugin changes, and returns plugin items.
src/extension/chatSessions/vscode-node/test/copilotCLICustomizationProvider.spec.ts Updates mocks and adds coverage for plugin items + plugin change invalidation.
src/extension/chatSessions/copilotcli/vscode-node/test/testHelpers.ts Updates test helper mock to include plugins and onDidChangePlugins.
src/extension/chatSessions/copilotcli/node/test/copilotCLISkills.spec.ts Updates test stub to satisfy new IChatPromptFileService members.
src/extension/chatSessions/copilotcli/node/test/copilotCliAgents.spec.ts Updates test stub to satisfy new IChatPromptFileService members.

@joshspicer joshspicer force-pushed the josh/plugins-chatpromptfiles-api branch from a4c45b5 to 54ab7e7 Compare April 3, 2026 17:03
@joshspicer joshspicer force-pushed the josh/plugins-chatpromptfiles-api branch from 54ab7e7 to b85db26 Compare April 3, 2026 17:22
Consume the new chat.plugins API and plumb it through to the
CopilotCLI customization provider:

- Mirror updated chatPromptFiles d.ts with ChatPluginResource
- Add plugins/onDidChangePlugins to IChatPromptFileService interface
- Wire vscode.chat.plugins in ChatPromptFileService implementation
- Add Plugins to CopilotCLI provider supportedTypes (unhides section)
- Add getPluginItems() to CopilotCLI provider
- Subscribe to onDidChangePlugins for provider invalidation
- Fix all test mocks for new interface member
- Add plugin tests (type, name, combined items, onDidChange)

Depends on: microsoft/vscode josh/plugins-chatpromptfiles-api
@joshspicer joshspicer force-pushed the josh/plugins-chatpromptfiles-api branch from 1b0e951 to 30b27ae Compare April 3, 2026 17:53
@joshspicer joshspicer marked this pull request as ready for review April 3, 2026 18:24
@joshspicer joshspicer added this pull request to the merge queue Apr 3, 2026
Merged via the queue into main with commit 92cc0a3 Apr 3, 2026
19 checks passed
@joshspicer joshspicer deleted the josh/plugins-chatpromptfiles-api branch April 3, 2026 19:54
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants