MCP.so
ログイン

comment-stripper-mcp

@yhzion

comment-stripper-mcp について

A flexible MCP server that batch processes code files to remove comments across multiple programming languages. Currently supports JavaScript, TypeScript, and Vue files with regex-based pattern matching. Handles individual files, directories (including subdirectories), and text i

基本情報

カテゴリ

その他

ランタイム

node

トランスポート

stdio

公開者

yhzion

設定

標準の設定はありません

このサーバーの README には解析可能な MCP 設定ブロックが含まれていません。インストール手順はリポジトリをご確認ください。

リポジトリ

ツール

ツールは検出されませんでした

ツールは README から自動的に抽出されます。メンテナーは ## Tools という見出しの下に記載することで、このタブに反映できます。

概要

What is comment-stripper-mcp?

comment-stripper-mcp is an MCP server that batch processes code files to remove comments across multiple programming languages using regex-based pattern matching. It supports JavaScript, TypeScript, Vue, CSS/SCSS/LESS, HTML, Python, Java, C#, C++, Ruby, and PHP files. The server is built with Node.js and TypeScript, following Test-Driven Development methodology.

How to use comment-stripper-mcp?

Install Node.js 18+, clone the repository, and install dependencies. Use npm run dev for development or npm run build && npm start for production. The server runs on port 3000 by default. Configure via environment variables in a .env file. The main endpoint is POST /api/strip-comments accepting text, filePath, directoryPath, recursive, fileTypes, and trackProgress parameters.

Key features of comment-stripper-mcp

  • Process files, directories, or raw text input
  • Cross-language support for 11 programming languages
  • Recursively handle nested directories
  • Regex-based pattern matching for efficient comment removal
  • MCP-compliant API for easy integration
  • Comprehensive logging with multiple levels
  • API authentication for secure access
  • Progress tracking for large directory processing

Use cases of comment-stripper-mcp

  • Clean code files before analysis or transformation
  • Remove comments from source code for minification or obfuscation
  • Strip comments from legacy codebases to simplify migration
  • Batch process multiple files across directories and subdirectories
  • Preprocess code before sending to language models or code review tools

FAQ from comment-stripper-mcp

How does comment-stripper-mcp remove comments?

It uses regex-based pattern matching specifically tailored for each supported language to identify and remove both single-line and multi-line comments.

What file types are supported?

JavaScript, TypeScript, Vue, CSS/SCSS/LESS, HTML, Python, Java, C#, C++, Ruby, and PHP files.

What are the runtime requirements?

Node.js 18 or higher, with npm or yarn installed.

How is the server configured?

Through environment variables defined in a .env file, covering port, host, log level, performance settings (chunk size, max workers, memory limit), and API authentication key.

How can I troubleshoot MCP connection issues with Claude Desktop?

Use absolute paths in the Claude Desktop config, ensure clean Node.js environment (e.g., via NVM), and check log files. The server includes stability improvements like process.stdin.resume() and keep-alive mechanisms.

コメント

「その他」の他のコンテンツ