返回市场
Git导入-mcp

Git导入-mcp

作者:narumiruna8 星标更新:2025-11-22

项目介绍

Gitingest MCP Server

一个与gitingest集成的Model Context Protocol (MCP)服务器实现,用于将任何Git仓库转换为其代码库的简单文本摘要。

<a href="https://glama.ai/mcp/servers/@narumiruna/gitingest-mcp"> <img width="380" height="200" src="https://gips2.baidu.com/it/u=2856276039,1358238654&fm=3081&app=3_081&f=PNG?w=760&h=400" alt="Gitingest Server MCP server" /> </a>

特性

  • 通过Model Context Protocol轻松集成AI助手
  • 具有分析和摄取Git仓库的能力
  • 支持按大小、模式和分支过滤文件
  • 返回全面的仓库信息,包括摘要、文件结构和内容

使用方法

配置选项

在您的AI助手设置中添加以下配置以启用gitingest-mcp作为MCP服务器:

PyPI安装

{
  "mcpServers": {
    "gitingestmcp": {
      "command": "uvx",
      "args": ["gitingestmcp@latest"]
    }
  }
}

GitHub安装

{
  "mcpServers": {
    "gitingestmcp": {
      "command": "uvx",
      "args": [
        "--from",
        "git+https://github.com/narumiruna/gitingest-mcp",
        "gitingestmcp"
      ]
    }
  }
}

本地安装

{
  "mcpServers": {
    "gitingestmcp": {
      "command": "uv",
      "args": [
        "run",
        "--directory",
        "/home/<user>/workspace/gitingest-mcp",
        "gitingestmcp"
      ]
    }
  }
}

API

该服务器提供以下工具:

ingest_git

分析Git仓库并返回其内容的结构化格式。

参数:

  • source: Git仓库的URL或本地目录路径
  • max_file_size (可选): 允许的最大文件大小(默认:10MB)
  • include_patterns (可选): 指定要包含的文件模式(例如,"*.md, src/")
  • exclude_patterns (可选): 指定要排除的文件模式
  • branch (可选): 要克隆和分析的分支(默认:"main")

返回值:

包含以下内容的字符串:

  1. 仓库摘要
  2. 文件的树状结构
  3. 仓库文件的内容

资源

许可证

详情见LICENSE文件。 </中文翻译>