G

GitHub Pera1连接器

@kazuph/mcp-github-pera1
Hosted
2 Stars 469 次浏览 kazuph 更新于 2026-08-23

一种将GitHub代码连接到Claude.ai的模型上下文协议服务器。该服务器利用Pera1服务从GitHub仓库中提取代码,并为Claude提供更好的上下文信息。

MCP 服务配置

复制以下 JSON 到 OPClaw 或其他 MCP 客户端的配置文件中即可使用

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

服务介绍

GitHub MCP Server for Pera1

一个连接GitHub代码到Claude.ai的模型上下文协议服务器。该服务器利用Pera1服务从GitHub仓库中提取代码,并为Claude提供更好的上下文。

设置

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

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

现在您可以向Claude询问有关GitHub代码仓库的问题了。

参数

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

使用示例

您可以向Claude提问如下:

Tell me about the implementation of GitHub repository https://github.com/username/repository

对于特定目录:

Explain the components in https://github.com/username/repository?dir=src/components

对于特定文件:

Show me the Button component from https://github.com/username/repository?file=src/components/Button.tsx

仅显示包含README文件的目录结构:

Show me the structure of https://github.com/username/repository?mode=tree

对于特定分支:

Analyze the develop branch of https://github.com/username/repository?branch=develop

许可证

MIT

作者

kazuph (https://x.com/kazuph)

相关 MCP 服务