Skip to main content
Glama

mcp-adr-analysis-server

by tosin2013
deploy-your-own-server.mdโ€ข4.55 kB
# NPM Publishing Guide This document explains how to publish the MCP ADR Analysis Server to npmjs.com using the automated GitHub Actions workflow. ## ๐Ÿš€ Quick Start ### Automatic Publishing (Recommended) 1. **Create a version tag:** ```bash git tag v1.0.1 git push origin v1.0.1 ``` 2. **The GitHub Actions workflow will automatically:** - Run all tests and linting - Build the project - Test MCP server functionality - Publish to npmjs.com - Create a GitHub release ### Manual Publishing 1. **Test the package locally:** ```bash npm run test:package ``` 2. **Publish manually:** ```bash npm publish ``` ## ๐Ÿ“‹ Prerequisites ### NPM Token Setup 1. **Create an NPM account** at https://www.npmjs.com/ 2. **Generate an access token:** - Go to https://www.npmjs.com/settings/tokens - Click "Generate New Token" - Choose "Automation" type - Copy the token 3. **Add token to GitHub Secrets:** - Go to your repository settings - Navigate to "Secrets and variables" โ†’ "Actions" - Add a new secret named `NPM_TOKEN` - Paste your NPM token as the value ## ๐Ÿ”ง Publishing Workflow Features ### Automated Quality Checks - โœ… ESLint code quality validation - โœ… Jest test suite execution - โœ… TypeScript compilation verification - โœ… MCP server functionality testing - โœ… Package structure validation ### Version Management - **Tag-based publishing**: Push a version tag to trigger publishing - **Manual versioning**: Use workflow dispatch with version input - **Automatic version updates**: Updates package.json version ### Package Optimization - **Selective file inclusion**: Only includes necessary files - **Size optimization**: ~173 KB optimized package - **Binary setup**: Includes CLI binary for global installation ## ๐Ÿ“ฆ Package Information ### Installation ```bash # Global installation npm install -g mcp-adr-analysis-server # Local installation npm install mcp-adr-analysis-server ``` ### Usage ```bash # Run as CLI tool mcp-adr-analysis-server # Or use as Node.js module node node_modules/mcp-adr-analysis-server/dist/src/index.js ``` ### Package Contents - **Main entry**: `dist/src/index.js` - **Binary**: `mcp-adr-analysis-server` command - **Documentation**: README.md and ../../LICENSE - **Type definitions**: Full TypeScript support ## ๐Ÿ”„ Version Management ### Semantic Versioning - **Patch** (1.0.1): Bug fixes and minor updates - **Minor** (1.1.0): New features, backward compatible - **Major** (2.0.0): Breaking changes ### Publishing Commands ```bash # Patch version (1.0.0 โ†’ 1.0.1) git tag v1.0.1 && git push origin v1.0.1 # Minor version (1.0.0 โ†’ 1.1.0) git tag v1.1.0 && git push origin v1.1.0 # Major version (1.0.0 โ†’ 2.0.0) git tag v2.0.0 && git push origin v2.0.0 ``` ### Manual Workflow Dispatch You can also trigger publishing manually: 1. Go to GitHub Actions tab 2. Select "Publish to NPM" workflow 3. Click "Run workflow" 4. Choose version type (patch/minor/major/prerelease) ## ๐Ÿ›ก๏ธ Security & Best Practices ### Token Security - โœ… NPM token stored as GitHub secret - โœ… Token only accessible to authorized workflows - โœ… Automatic token rotation recommended ### Quality Gates - โœ… All tests must pass before publishing - โœ… Linting must pass before publishing - โœ… Build must succeed before publishing - โœ… MCP server functionality verified ### Package Integrity - โœ… Package contents verified before publishing - โœ… Main entry point validated - โœ… Binary accessibility confirmed - โœ… Size optimization applied ## ๐Ÿ“Š Monitoring & Maintenance ### NPM Package Stats - **Package page**: https://www.npmjs.com/package/mcp-adr-analysis-server - **Download stats**: Available on NPM package page - **Version history**: Tracked in NPM registry ### GitHub Releases - **Automatic releases**: Created for each published version - **Release notes**: Generated with feature highlights - **Asset downloads**: Package tarballs available ## ๐Ÿ”ง Troubleshooting ### Common Issues 1. **NPM Token Invalid** - Regenerate token on npmjs.com - Update GitHub secret 2. **Tests Failing** - Check test output in GitHub Actions - Fix issues locally and push 3. **Package Size Too Large** - Review .npmignore file - Remove unnecessary files 4. **Binary Not Working** - Verify package.json bin configuration - Test locally with `npm run test:package` ### Support For issues with the publishing process, check: - GitHub Actions logs - NPM package page - Repository issues section

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/tosin2013/mcp-adr-analysis-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server