MCP Catalogs
首页

code-mcp

by 54yyyu·37·综合分 38

Code-MCP 通过 MCP 将 Claude AI 连接到开发环境,允许通过 AI 界面执行终端命令和文件操作。

developer-toolsai-llmproductivity
3
Forks
3
活跃 Issue
14 个月前
最近提交
2 天前
收录于

概述

Code-MCP 是一个基于 Python 的 MCP 服务器,将 Claude AI 与本地开发环境连接,使 AI 能够执行终端命令、执行文件操作、处理 git 仓库以及对代码库应用智能编辑功能。它提供了全面的安装选项,包括 macOS/Linux/Windows 的一键安装方式,并支持可选功能如通过 SSH 的远程连接和 Jupyter notebook 集成。该服务器包含针对破坏性操作的安全机制,确保所有操作都保持在项目目录内。

试试问 AI

装完之后,这里有 6 个你可以让 AI 做的事:

:让 Claude AI 通过终端命令和文件操作直接与代码库交互
:通过连接到远程服务器上运行的 Code-MCP 实例来处理远程代码库
:使用模式匹配和函数级操作执行代码分析和编辑
:Code-MCP 是否与 Claude API 兼容,还是只支持 Claude Desktop?
:Code-MCP 是否支持远程开发环境?
:Code-MCP 实现了哪些安全功能?

什么时候选它

当您需要 Claude AI 通过终端命令和文件操作直接与本地或远程开发环境交互时,选择 Code-MCP。

什么时候不要选它

如果您需要多用户协作功能,或需要比文件操作和命令执行更复杂的工作流自动化,则应避免使用。

此 server 暴露的工具

从 README 抽取出 9 个工具
  • run_command

    Execute terminal commands in the project directory

  • git_operation

    Perform git operations with safety confirmations

  • read_file

    Read the content of a file

  • edit_file

    Edit a file with specified changes

  • smart_edit

    Perform smart code editing with pattern matching

  • create_directory

    Create a new directory

  • delete_path

    Delete a file or directory with confirmation

  • list_directory

    List contents of a directory

  • edit_block

    Perform batch operations across multiple files

可对比工具

shell-mcpfilesystem-mcpgithub-mcp

安装

安装

快速安装

**macOS / Linux:**

curl -LsSf https://raw.githubusercontent.com/54yyyu/code-mcp/main/install.sh | sh

**Windows:**

powershell -c "Invoke-WebRequest -Uri https://raw.githubusercontent.com/54yyyu/code-mcp/main/install.ps1 -OutFile install.ps1; .\install.ps1"
Claude Desktop 集成
  1. 使用项目路径运行设置助手:
code-mcp-setup /path/to/your/project
  1. 或手动编辑 Claude Desktop 配置 (claude_desktop_config.json):
{
    "mcpServers": {
        "code": {
            "command": "code-mcp",
            "args": [
                "/path/to/your/project"
            ]
        }
    }
}

FAQ

Code-MCP 是否与 Claude API 兼容,还是只支持 Claude Desktop?
Code-MCP 主要通过 MCP 为 Claude Desktop 设计集成。虽然可能与 Claude API 集成,但主要用例和文档重点放在 Claude Desktop 上。
Code-MCP 是否支持远程开发环境?
是的,Code-MCP 支持 SSH 远程连接。您可以使用提供的设置脚本和命令行工具将 Claude Desktop 连接到运行在远程服务器上的 Code-MCP 实例。
Code-MCP 实现了哪些安全功能?
Code-MCP 包含对破坏性操作(删除、覆盖)的确认要求、路径安全以防止在项目目录外操作,以及对潜在危险的 git 命令的特殊确认。

code-mcp 对比

GitHub →

最后更新于 · 由 README + GitHub 公开数据自动生成。