Skip to content

feat: csdd MCP server (dev-flow tools) + npm distribution#4

Merged
protonspy merged 2 commits into
mainfrom
fix/npm-launcher-gitignore
May 31, 2026
Merged

feat: csdd MCP server (dev-flow tools) + npm distribution#4
protonspy merged 2 commits into
mainfrom
fix/npm-launcher-gitignore

Conversation

@protonspy
Copy link
Copy Markdown
Owner

Summary

Brings two things to main: the npm distribution of the csdd CLI (npx launcher + release pipeline) and a Model Context Protocol server that exposes the csdd development flow as typed tools, wired into csdd init.

npm distribution

  • Root launcher @protonspy/csdd + per-platform prebuilt-binary packages, published by the release workflow (make release).
  • Makefile for build/test/dist/publish; CI gate reused by the release pipeline; .gitignore/.npmignore hygiene; docs updated for npx @protonspy/csdd usage.

MCP server (@protonspy/csdd-mcp)

  • Stdio server exposing the development-flow resources as tools — csdd_steering_*, csdd_spec_*, csdd_skill_*, csdd_agent_*, plus csdd_version (27 tools). Each builds the csdd argv and shells out headlessly; exit 2 (validation) is surfaced distinctly.
  • Scope by design: setup/management (init, mcp, export) are intentionally not tools — one-time CLI operations, not agent-loop steps.
  • Zero-dependency unit tests via Node's built-in node:test (argv builders, result formatting, binary resolution, runCsdd against a stub, every tool's argv mapping). Wired into CI on Node 24.
  • optionalDependencies on the per-platform csdd binaries → npx @protonspy/csdd-mcp self-fetches the matching binary (zero-config); override with CSDD_BIN.

Integration

  • csdd init registers the csdd MCP server in .mcp.json by default (--no-mcp to skip); idempotent, portable entry (npx -y @protonspy/csdd-mcp, no absolute paths).
  • CLAUDE.md + csdd.md now document the MCP-first dev flow: prefer the typed csdd_* tools (validated artifact/phase/inclusion enums → fewer invalid invocations); the CLI stays the source of truth and the fallback.

Testing

  • Go: go test ./... green (incl. new init-registration tests; adjusted two tests that assumed an empty .mcp.json).
  • MCP server: npm test green — 27 tools, 67 tests; npm ci lockfile in sync.
  • E2E smoke: csdd init registers the server; resolveCsddBin() finds the optionalDependency binary (csdd v0.1.1).

Notes

  • Pre-existing CRLF line-ending churn in the working tree (LICENSE, go.mod, ~20 templates) is not included — line-ending noise, not content.
  • csdd-mcp optionalDependencies pin ^0.1.0 (current csdd 0.1.x line); a follow-up could wire mcp-server into the release pipeline for exact version lockstep.

🤖 Generated with Claude Code

protonspy and others added 2 commits May 31, 2026 16:22
Trim the csdd MCP server to the iterative development-flow resources
(steering, spec, skill, agent) plus a version diagnostic — 27 tools.
Remove the setup/management tools (init, mcp; export was already gone):
those stay CLI-only, one-time human operations rather than agent-loop tools.

- csdd init now registers the `csdd` MCP server in .mcp.json by default
  (stdio via `npx -y @protonspy/csdd-mcp`); `--no-mcp` opts out. Idempotent.
- csdd-mcp declares the per-platform csdd binaries as optionalDependencies,
  so `npx @protonspy/csdd-mcp` self-fetches the matching binary (zero-config).
- Document the MCP-first dev flow in CLAUDE.md and csdd.md: prefer the typed
  `csdd_*` tools (more precise than hand-written commands); setup and
  management remain on the CLI.
- Update READMEs and trim the tool tests; adjust two CLI tests that assumed
  an empty .mcp.json now that init registers a server.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@protonspy protonspy merged commit ae422cc into main May 31, 2026
2 checks passed
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