fix: use relative path in .mcp.json to avoid CLAUDE_PLUGIN_ROOT warning

${CLAUDE_PLUGIN_ROOT} is only defined when the repo is loaded as an installed
Claude Code plugin. When contributors open the repo as a regular project, the
variable is undefined and Claude Code prints:

  [Warning] mcpServers.context-mode: Missing environment variables: CLAUDE_PLUGIN_ROOT

Use a relative path so the MCP entry works for repo-as-project usage. Plugin
install path is unaffected — it still uses .claude-plugin/plugin.json.

Closes #251

Co-authored-by: Ercan Ermis <eposta@ercanermis.com>
This commit is contained in:
Ercan
2026-04-13 01:35:39 +03:00
parent 0020267626
commit 1106e03a7a
+1 -1
View File
@@ -2,7 +2,7 @@
"mcpServers": {
"context-mode": {
"command": "node",
"args": ["${CLAUDE_PLUGIN_ROOT}/start.mjs"]
"args": ["./start.mjs"]
}
}
}