Skip to content

build: distribute as standalone @deploygate/mcp npm package#26

Open
tnj wants to merge 6 commits into
mainfrom
feat/npm-distribution
Open

build: distribute as standalone @deploygate/mcp npm package#26
tnj wants to merge 6 commits into
mainfrom
feat/npm-distribution

Conversation

@tnj
Copy link
Copy Markdown
Member

@tnj tnj commented May 27, 2026

Summary

Distribute the DeployGate MCP server as a standalone npm package (npx @deploygate/mcp) in addition to the existing git-based Claude Code / Codex plugin marketplace — from the same repo, same source, single version.

  • package.json: renamed to the scoped @deploygate/mcp; bin points at the existing zero-dependency esbuild bundle (plugin/scripts/bundle.js); files trimmed to bundle + README + LICENSE; @modelcontextprotocol/sdk and zod moved to devDependencies (the published package has zero runtime dependencies — the bundle inlines them); main removed (CLI/server, not a library); publishConfig.access: public added.
  • release.yml: a release_created-gated step sequence (npm install -g npm@latestnpm cinpm run bundlenpm publish) added to the existing release-please job, authenticating via npm trusted publishing (OIDC)permissions: id-token: write, no long-lived token.
  • README.md: new "Standalone MCP server (any MCP client)" section with the npx config example (Claude Desktop / Cursor / Cline) and the shared-token auth note.
  • .gitignore: ignore docs/superpowers/ (agent workflow design docs stay local, untracked).
  • Tests: packaging-invariant assertions added to plugin.test.ts (name, bin target exists, trimmed files, public access, zero runtime deps, no main).

The git-based plugin marketplace distribution is unchanged.

Test Plan

  • npm run build clean, npm test green (incl. new packaging tests)
  • npm pack --dry-run ships exactly package.json, plugin/scripts/bundle.js, LICENSE, README.md
  • Bin smoke test: printf '<initialize JSON>' | node plugin/scripts/bundle.js returns a valid MCP initialize result (server starts from the bundle)
  • release.yml YAML parses; publish steps are release_created-gated with id-token: write and no token env
  • (post-merge) Complete the npm prerequisites above, then verify the first release publishes @deploygate/mcp via OIDC

🤖 Generated with Claude Code

@tnj tnj force-pushed the feat/npm-distribution branch from f220831 to 0a51f35 Compare May 27, 2026 04:02
tnj and others added 5 commits May 28, 2026 11:57
Rename to the scoped @deploygate/mcp, point bin at the zero-dependency
bundle, trim files to bundle+README+LICENSE, move sdk/zod to
devDependencies (zero runtime deps), drop the library main entry, and
publish publicly. Add packaging-invariant tests.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Add a release_created-gated step sequence to the release-please job that
runs npm ci + npm run bundle + npm publish, authenticating with the
NPM_TOKEN secret. Triggers on the first release after this merges.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Add an Installation subsection covering npx @deploygate/mcp for any MCP
client, with a config example and the shared-token auth note.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Replace the NPM_TOKEN secret with npm trusted publishing (OIDC): grant
id-token: write, ensure npm >= 11.5.1, and drop NODE_AUTH_TOKEN from
npm publish. Requires configuring a trusted publisher for @deploygate/mcp
on npmjs.com (package must be published once first to enable it).

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@tnj tnj force-pushed the feat/npm-distribution branch from 45ab70d to f2a9177 Compare May 28, 2026 03:01
@tnj tnj requested a review from Copilot May 28, 2026 03:08

This comment was marked as resolved.

@tnj
Copy link
Copy Markdown
Member Author

tnj commented May 28, 2026

/gemini review

gemini-code-assist[bot]

This comment was marked as resolved.

- plugin.test.ts: assert plugin/scripts/bundle.js starts with
  `#\!/usr/bin/env node`, locking the invariant that esbuild preserves
  from src/index.ts.
- README: replace the duplicated `~/.config/deploygate/token` note in
  the standalone-npx section with a link to the existing Authentication
  section, which already documents the Windows path.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Copy link
Copy Markdown

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

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

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 3 additional findings.

Open in Devin Review

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.

2 participants