Skip to main content
Glama
shibdad

GitHub MCP Server

🔗 适用于 Claude Desktop 的 GitHub MCP 服务器

通过无缝 GitHub 集成增强您的 Claude Desktop!

该 MCP 服务器将 Claude Desktop 直接连接到您的 GitHub 存储库和 git 命令,让您可以通过自然对话与您的代码和存储库进行交互。

✨ 特点

  • 🔄 git-clone - 通过简单的请求克隆任何存储库

  • 📊 git-status - 检查你的 git 仓库中发生的情况

  • 📋 github-list-repos - 浏览你的 GitHub 存储库

  • 🔍 github-repo-info - 获取任何存储库的详细信息

  • 📝 git-commit - 提交对存储库的更改

  • 🚀 git-push - 将你的提交推送到 GitHub

  • 🆕 github-create-repo - 创建新的 GitHub 存储库

Related MCP server: GitHub MCP Server

🚀 快速入门

  1. 克隆此 repo:

    git clone https://github.com/shibdad/github-mcp-server.git
    cd github-mcp-server
  2. 安装依赖项:

    npm install
  3. 使其可执行:

    chmod +x start.sh index.js
  4. 添加您的 GitHub 令牌(用于私人存储库和 API 访问):

    echo "your-github-token" > .github_token
  5. 将其连接到 Claude Desktop:

    编辑 Claude 的配置文件:

    • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

    • Windows: %APPDATA%\Claude\claude_desktop_config.json

    将其添加到您的配置中:

    {
      "mcpServers": {
        "github": {
          "command": "/bin/sh",
          "args": ["-c", "/path/to/github-mcp-server/start.sh"]
        }
      }
    }
  6. 重新启动 Claude,就可以了!

💬 尝试这些提示

连接后,向 Claude 询问以下问题:

  • “将 tensorflow/models 存储库克隆到我的下载文件夹”

  • “我的项目目录的 git 状态是什么?”

  • “显示我的 GitHub 存储库列表”

  • “获取有关 microsoft/vscode 存储库的详细信息”

  • “通过‘更新文档’消息提交我的更改”

  • “将我的提交推送到 GitHub”

  • “创建一个名为‘my-awesome-project’的新存储库”

🔧 要求

  • Node.js 16+

  • Git 命令行工具

  • 克劳德桌面

  • GitHub 个人访问令牌(用于 API 访问)

🔒 GitHub 令牌选项

需要访问私有代码库?您可以通过以下方式添加您的代币:

  1. 在项目文件夹中创建.github_token文件

  2. 设置GITHUB_TOKEN环境变量

  3. 直接在 Claude 的配置中添加它:

    {
      "mcpServers": {
        "github": {
          "command": "/bin/sh",
          "args": ["-c", "/path/to/github-mcp-server/start.sh"],
          "env": {
            "GITHUB_TOKEN": "your-github-token"
          }
        }
      }
    }

🙋‍♂️ 贡献

发现 Bug 了吗?想添加新功能吗?欢迎提交 PR!

📜 许可证

麻省理工学院

A
license - permissive license
Not graded
quality - not tested
Not graded
maintenance - not tested

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables interaction with GitHub through the GitHub API, supporting file operations, repository management, advanced search, and issue tracking with comprehensive error handling and automatic branch creation.
    452
    1
    ISC
  • F
    license
    Not graded
    quality
    D
    maintenance
    A modular command processor server that enables interaction with GitHub's REST API to fetch user details, repository information, and authenticated user data through natural language commands in Claude.
  • F
    license
    Not graded
    quality
    D
    maintenance
    A Multi-Claude Program for interacting with GitHub APIs through Claude Desktop, allowing users to search repositories, manage issues, pull requests, repository settings, workflows, and collaborators.
    1

View all related MCP servers

Related MCP Connectors

  • Connect AI assistants to GitHub - manage repos, issues, PRs, and workflows through natural language.

  • Connect AI assistants to your GitHub-hosted Obsidian vault to seamlessly access, search, and analy…

  • Connect Claude to Fathom meeting recordings, transcripts, and summaries

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/shibdad/github-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server