Skip to content

feat: manage MCP server configs across agents - #17

Merged
machado144 merged 2 commits into
mainfrom
feat/006-mcp-configs
Jul 11, 2026
Merged

feat: manage MCP server configs across agents#17
machado144 merged 2 commits into
mainfrom
feat/006-mcp-configs

Conversation

@machado144

Copy link
Copy Markdown
Contributor

What

New mcp artifact kind: define an MCP server once (mcps/<name>/mcp.yaml), loadout merges it into each agent's native MCP config through the normal plan → confirm → apply gate.

command: npx
args: ["-y", "@modelcontextprotocol/server-github"]
env:
  GITHUB_TOKEN: ${GITHUB_TOKEN}
scope: user   # or project
Agent user scope project scope
claude-code ~/.claude.json <project>/.mcp.json
gemini-cli ~/.gemini/settings.json <project>/.gemini/settings.json
cursor ~/.cursor/mcp.json <project>/.cursor/mcp.json
  • Secrets never enter the store: secret-looking env/header keys must use ${VAR} placeholders (passed through verbatim); literals are rejected at new/add, doctor, bundle import, and sync render.
  • New engine surface: TargetFile.Root (agent-home / user-home / project), --project on sync/status/diff, root-qualified state keys (old state files load unchanged), path-escape fence on every target, root-aware snapshots.
  • Bundles round-trip MCP artifacts through dir, tar.gz and flat YAML (kind-generic already — plus an import-time secret gate).
  • Codex (TOML comment-preservation blocker) and Antigravity (unverified path) report n/a — parked in ROADMAP with rationale.

Spec: docs/specs/006-mcp-configs.md (+ plan, R9 amended to match the repo's new/add split).

Tests

  • Unit: MCPSpec parse/secret-gate tables, per-adapter render (both scopes), engine root resolution + fence + root-qualified state, bundle round-trip ×3 formats + tampered-secret rejection.
  • Integration (real binary, temp HOME): sync writes all three agents' configs; no-confirm-no-write invariant extended to user-home + project roots; project scope via --project (state stays in the data dir); hand-edit → drifted-local, foreign mcpServers entries survive re-sync; literal secret refused end-to-end.
  • make ci + make test-integration green; internal/web/dist rebuilt (mcp glyph).

🤖 Generated with Claude Code

New 'mcp' artifact kind (mcps/<name>/mcp.yaml) rendered into each agent's
native MCP config via json-merge: claude-code (~/.claude.json / .mcp.json),
gemini-cli (settings.json), cursor (mcp.json). Secrets are ${VAR}
placeholders only — literals rejected at new/add, doctor, bundle import and
render. Adds TargetFile.Root (agent-home/user-home/project), --project
scope, root-qualified state keys and a path-escape fence. Codex/antigravity
MCP parked in ROADMAP. Spec 006 + plan included.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

✅ PR title follows the required format

Current title: feat: manage MCP server configs across agents

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@machado144
machado144 merged commit 655f0c6 into main Jul 11, 2026
5 checks passed
@machado144
machado144 deleted the feat/006-mcp-configs branch July 11, 2026 21:15
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.

1 participant