filesystem vs git
并排对比,帮你在这两个 MCP server 之间做选择。
filesystem by modelcontextprotocol | git by modelcontextprotocol | |
|---|---|---|
| Stars | ★ 85,748 | ★ 85,748 |
| 30天用量 | — | — |
| 综合分 | 77 | 75 |
| 官方 | ✓ | ✓ |
| 分类 | 本地文件系统开发者工具效率工具 | 开发者工具本地文件系统效率工具 |
| 实现语言 | TypeScript | TypeScript |
| 最近提交 | 本月 | 本月 |
filesystem · 概述
功能丰富的文件系统操作 MCP 服务器,具有动态目录访问控制功能。
git · 概述
功能全面的 Git 操作 MCP 服务器,支持状态查看、差异比较、提交和分支管理。
filesystem · 使用场景
- 使 AI 模型能够读取和写入项目文件进行开发
- 允许 Claude 或其他 MCP 客户端浏览和分析代码库
- 为内容生成提供对特定目录的安全沙盒访问
git · 使用场景
- AI 驱动的 Git 仓库分析和管理
- 通过差异检查进行自动化代码审查
- 分支管理和工作流程自动化
filesystem · 安装
安装
使用 NPX
{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-filesystem",
"/path/to/allowed/directory"
]
}
}
}使用 Docker
{
"mcpServers": {
"filesystem": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"--mount", "type=bind,src=/path/to/allowed/dir,dst=/projects/allowed/dir",
"mcp/filesystem",
"/projects"
]
}
}
}VS Code 扩展
点击 README 中的安装按钮直接在 VS Code 中安装。
git · 安装
使用 uv(推荐)
当使用 [uv](https://docs.astral.sh/uv/) 时,无需特定安装。使用 [uvx](https://docs.astral.sh/uv/guides/tools/) 直接运行服务器:
uvx mcp-server-git --repository path/to/git/repo使用 PIP
或者通过 pip 安装 mcp-server-git:
pip install mcp-server-git安装后,按如下方式运行:
python -m mcp_server_gitClaude Desktop 配置
添加到您的 claude_desktop_config.json:
"mcpServers": {
"git": {
"command": "uvx",
"args": ["mcp-server-git", "--repository", "path/to/git/repo"]
}
}