Back to MCP directory
publicPublicdnsLocal runtime

mcp-github-pera1

GitHub代码与Claude.ai连接的MCP服务器,通过Pera1服务提取GitHub仓库代码并提供上下文增强。

article

README

🚀 GitHub MCP 服务器用于 Pera1

这是一个模型上下文协议(Model Context Protocol)服务器,其核心价值在于将 GitHub 代码与 Claude.ai 进行连接。借助 Pera1 服务,该服务器能够从 GitHub 仓库中精准提取代码,为 Claude 提供更优质的上下文信息,从而提升交互体验。

🚀 快速开始

此服务器能使 Claude 与 GitHub 代码仓库建立连接,让你可以轻松地让 Claude 查询 GitHub 代码仓库的信息。

📦 安装指南

在你的 MCP 配置文件(~/Library/Application Support/Claude/claude_desktop_config.json)中添加以下内容:

{
  "mcpServers": {
    "github": {
      "command": "npx",
      "args": ["-y", "@kazuph/mcp-github-pera1"]
    }
  }
}

💻 使用示例

基础用法

你可以向 Claude 提出以下基础问题:

告诉我关于GitHub仓库 https://github.com/username/repository 的实现细节。

高级用法

特定目录查询

解释https://github.com/username/repository?dir=src/components 中的组件结构。

指定文件查询

展示https://github.com/username/repository?file=src/components/Button.tsx 中的Button组件代码。

特定显示模式

展示https://github.com/username/repository 的文件结构(仅包含README)?mode=tree

特定分支查询

分析https://github.com/username/repository 的develop分支情况?branch=develop

📚 详细文档

参数说明

| 属性 | 详情 | |------|------| | url | GitHub 仓库的 URL 地址(必填) | | dir | 按目录路径过滤文件(逗号分隔) | | ext | 按文件扩展名过滤文件(逗号分隔) | | mode | 显示模式(例如,tree 仅显示目录结构和 README 文件) | | branch | 指定要获取的分支 | | file | 指定要检索的单个文件 |

📄 许可证

本项目采用 MIT 许可证。

👨‍💻 作者

kazuph(联系作者

help

Runtime guide

cloud

Hosted runtime

Hosted servers run from a provider-managed environment. You usually connect the MCP client to the hosted endpoint or follow the provider's authorization flow, without keeping a local process alive

  1. Open provider connection page
  2. Authorize or copy endpoint
  3. Connect from your MCP client
terminal

Local runtime / other methods

Local servers run on your own machine or infrastructure. You normally copy the server_config into your MCP client, install the required package, and provide env variables from env_schema when needed

  1. Copy server_config
  2. Install required package
  3. Fill env variables and restart client