feat: add support for JetBrains AI Assistant MCP configuration#2330
Open
besdar wants to merge 4 commits into
Open
feat: add support for JetBrains AI Assistant MCP configuration#2330besdar wants to merge 4 commits into
besdar wants to merge 4 commits into
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.
This PR adds MCP (Model Context Protocol) configuration generation support for JetBrains AI Assistant, enabling rulesync to generate
.ai/mcp/mcp.json(project) and~/.ai/mcp/mcp.json(global) from the unified.rulesync/.mcp.jsonsource file.Previously, JetBrains AI Assistant was the only major JetBrains tool without MCP support in rulesync. JetBrains Junie already had MCP support, and this PR brings the same capability to AI Assistant — including both project-level and global (user-level) scope.
Changes
New files
src/features/mcp/aiassistant-mcp.ts— NewAiassistantMcpclass implementing MCP generation for JetBrains AI Assistantsrc/features/mcp/aiassistant-mcp.test.ts— Unit tests forAiassistantMcpModified files
src/constants/aiassistant-paths.ts— AddedAIASSISTANT_MCP_DIR_PATHandAIASSISTANT_MCP_FILE_NAMEconstants for the.ai/mcp/mcp.jsonpathsrc/types/tool-target-tuples.ts— Added"aiassistant"tomcpProcessorToolTargetTuplesrc/features/mcp/mcp-processor.ts— RegisteredAiassistantMcpin the tool MCP factories map withsupportsProject: trueandsupportsGlobal: truesrc/e2e/e2e-mcp.spec.ts— Addedaiassistantto both project and global e2e MCP generation matrix testsREADME.md— Updated Supported Tools table:mcpcolumn now shows ✅ for JetBrains AI Assistantdocs/reference/supported-tools.md— Updated detailed supported tools reference:mcpcolumn shows✅ 🌏skills/rulesync/supported-tools.md— Updated skills-distributed supported tools referenceGenerated file format
The generated
.ai/mcp/mcp.json(and~/.ai/mcp/mcp.jsonfor global scope) follows the standardmcpServersJSON format that JetBrains AI Assistant reads natively:{ "mcpServers": { "my-server": { "command": "npx", "args": ["-y", "@modelcontextprotocol/server-filesystem", "/path/to/dir"] } } }Usage
Scope support
.ai/mcp/mcp.json~/.ai/mcp/mcp.jsonThe relative path is identical for both scopes; the base directory changes (project working directory for project scope, home directory for global scope). This follows the same pattern used by JetBrains Junie.
References