#!/usr/bin/env bash # Alternative: run the server yourself as a local binary (stdio), read-only. # Download github-mcp-server v2.0.3 for your platform from # https://github.com/github/github-mcp-server/releases/tag/v2.0.3 # put it on your PATH, check it with `github-mcp-server --version`, then run # this script from your project root with GITHUB_MCP_PAT exported. set -euo pipefail claude mcp add-json github '{ "command": "github-mcp-server", "args": ["stdio", "--read-only", "--toolsets", "context,repos,issues,pull_requests"], "env": { "GITHUB_PERSONAL_ACCESS_TOKEN": "${GITHUB_MCP_PAT}" } }' claude mcp get github