@kazuph/mcp-github-pera1
Pera1 的 GitHub MCP 服务器
一个模型上下文协议服务器,用于将 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仅显示目录结构和自述文件)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执照
麻省理工学院
作者
kazuph( https://x.com/kazuph )
Available Tools
1 toolgithub_get_codeA
Retrieves code from a GitHub repository URL and combines it into a single file. The URL must start with "https://".
Query Parameters:
dir: Filter files by directory paths (comma-separated) Example: ?dir=src/components,tests/unit
ext: Filter files by extensions (comma-separated) Example: ?ext=ts,tsx,js
mode: Display mode Example: ?mode=tree (Shows directory structure and README files only)
branch: Specify the branch to fetch from (optional) Example: ?branch=feature/new-feature
file: Specify a single file to retrieve (optional) Example: ?file=src/components/Button.tsx
Examples:
For GitHub tree URLs with branch: https://github.com/kazuph/pera1/tree/feature/great-branch This URL will be automatically parsed to extract the branch information.
For specific directory in a branch: url: https://github.com/modelcontextprotocol/servers dir: src/fetch branch: develop
For a single file: url: https://github.com/username/repository file: src/components/Button.tsx
For directory structure with README files only: url: https://github.com/username/repository mode: tree
The tool will correctly parse the repository structure and fetch the files from the specified branch.
Inputs: url (required), dir, ext, mode, +2 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 1 tool
Only one tool exists, so there is no risk of confusion between tools.
The single tool follows a consistent verb_noun pattern (github_get_code).
A single tool for code retrieval is very minimal; users might expect additional GitHub operations, making the server feel incomplete.
For the stated purpose of retrieving code from a GitHub repository, the tool covers key needs with filtering by directory, extension, branch, and single file, as well as a tree mode. Minor gap: no support for private repos or authentication details in the description.
Maintenance
Related MCP Connectors
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
An MCP server that gives your AI access to the source code and docs of all public github repos
Shared memory MCP server for Claude Code, Codex, Gemini CLI and Cursor. Cited, editable.
A Model Context Protocol (MCP) application for automated GitHub PR analysis and issue management.…
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceA Model Context Protocol server that enables AI assistants like Claude to interact with GitHub repositories, issues, and pull requests.ISC
- AlicenseNot gradedqualityDmaintenanceModel Context Protocol server that enables Claude to retrieve and analyze code from GitHub repositories through the uithub API.21MIT
- FlicenseNot gradedqualityNot gradedmaintenanceA Model Context Protocol server that provides comprehensive GitHub integration for Claude Desktop, allowing users to manage repositories, issues, and pull requests. It supports file operations, branch management, and repository searches through natural language commands.330 npm-
- AlicenseCqualityCmaintenanceA Model Context Protocol (MCP) server that enables AI assistants like Claude to interact with the GitHub API directly.23MIT