GitHub Workspace MCP Server
Fetches arXiv paper metadata by arxiv_id when scaffolding new reading-note drafts, so notes start pre-filled with the paper's title/authors/abstract.
Returns per-PR-branch Cloudflare Pages preview URLs after opening or updating a pull request, so generated static HTML/Markdown pages can be reviewed instantly without deploying.
Core integration: browses, searches and reads repository files, manages work branches, and performs atomic multi-file commits and PR creation/updating via the GitHub REST & Git Data API, authenticated through GitHub OAuth 2.1 (allowlisted users) plus a fine-grained PAT with minimal repo permissions.
Optional per-repository static page publishing mode; after a PR is opened the server returns the GitHub Pages preview link for the branch's content.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
github-workspace-mcp
一个零本地 Git Clone、支持多仓库配置、零公网入站端口暴露的远端 GitHub Workspace MCP 服务器,专为小磁盘 VPS(如 10 GB 服务器)和移动端/平板协作(如通过 Gemini 网页端 / 平板 PWA 边读论文边写笔记与交互式 HTML 页面、自动提 PR)设计。
核心特性
10 GB 小磁盘友好(零 Clone 架构):不在服务器本地做任何
git clone,所有读写与原子多文件提交全部通过 GitHub REST & Git Data API 完成,配合带容量上限(默认 30 MB)和自动清理的轻量 SQLite 草稿箱,整体磁盘占用仅 ~150 MB。绝对不暴露 8080 端口:程序默认强制仅绑定
127.0.0.1:8080(代码层面拦截非本机绑定),通过 Cloudflare Tunnel (cloudflared) 建立出站加密隧道暴露 HTTPS,服务器防火墙可关闭所有入站端口。标准远端 MCP 鉴权(GitHub OAuth 2.1):完整支持 Streamable HTTP (
/mcp)、/.well-known/oauth-*发现、PKCE 与动态客户端注册,通过你的 GitHub OAuth App 登录并校验ALLOWED_GITHUB_USERS白名单;仓库写操作与身份认证解耦,使用最小权限的 Fine-grained PAT。多仓库 + 可选工作流 Preset:通过
repos.yaml纳管任意数量仓库;支持为特定仓库(如edge-mt-lab)启用reading_notespreset(自动解析/更新论文进度表、套用模板、拉取 arXiv 元信息)。静态页面零负担预览:原生支持 Cloudflare Pages(每个 PR 分支自动生成独立预览 URL)与 GitHub Pages,提 PR 后自动返回静态页预览链接。
便捷 Shell 管理命令 (
gw-mcp):交互式初始化、多仓库增删改、健康体检(磁盘/绑定/权限)、systemd 服务控制与一键清理缓存。
Related MCP server: github-mcp-tool
快速开始
1. 服务器一键安装
bash scripts/install.sh或者手动使用 uv 安装:
uv sync
uv run gw-mcp init2. 配置 GitHub OAuth App 与 Fine-grained PAT
GitHub OAuth App(用于登录认证):
打开 GitHub
Settings → Developer settings → OAuth Apps → New OAuth AppAuthorization callback URL 填:
https://mcp.你的域名/oauth/github/callback将
Client ID和Client Secret填入.env(或gw-mcp init向导)设置
ALLOWED_GITHUB_USERS=你的GitHub用户名
Fine-grained PAT(用于写指定仓库与提 PR):
打开
Settings → Developer settings → Personal access tokens → Fine-grained tokensRepository access:仅勾选你打算纳管的仓库
Permissions:
Contents: Read and write、Pull requests: Read and write
3. 配置 Cloudflare Tunnel(零公网入站端口)
gw-mcp tunnel guide配置模板见 deploy/cloudflared-config.example.yaml。如果你服务器上已有 Caddy 跑在 443,也可参考 deploy/caddy.Caddyfile.example。
4. 管理多仓库与启动服务
# 添加支持 Cloudflare Pages 预览和论文笔记 Preset 的仓库
gw-mcp repo add edge-mt-lab cheese1QAQ/edge-mt-lab \
--pages cloudflare_pages \
--preset-reading-notes
# 再添加任意其他仓库(通用文档/博客工作流)
gw-mcp repo add my-notes cheese1QAQ/my-notes --pages github_pages
# 校验配置与 GitHub Token 权限
gw-mcp config check
# 运行小盘与安全体检
gw-mcp doctor
# 安装并启动 systemd 后台服务
sudo gw-mcp service install
sudo gw-mcp service start5. 在 Gemini 网页端 / 平板 PWA 接入
在 PC 浏览器打开
gemini.google.com→ Settings → Connected Apps → Custom Apps;填入远端 MCP 地址:
https://mcp.你的域名/mcp;按提示跳转 GitHub OAuth 登录(仅白名单账号可授权通过);
在平板浏览器(Safari / Chrome)打开
gemini.google.com并 添加到主屏幕(PWA),即可在教室像原生 App 一样对话编辑 Markdown / 交互式 HTML 笔记、提 PR 并在 Cloudflare Pages 上直接预览效果。
MCP 工具列表(13 个)
分类 | 工具 | 说明 |
通用 |
| 查看所有已配置仓库、活跃分支与启用 preset |
通用 |
| 列出或切出允许前缀的工作分支(禁止直写 |
通用 |
| 浏览、检索与读取文件(自动融合当前未提交草稿) |
通用 |
| 新建/覆盖、分块追加超长 HTML、局部精确修改 |
通用 |
| 查看当前分支所有草稿变更与 unified diff |
通用 |
| 通过 GitHub Git Data API 原子提交、开/更新 PR 并返回静态页预览链接 |
Preset |
| 解析并筛选论文进度表(需启用 |
Preset |
| 切分支 + 套模板生成笔记草稿(支持 |
Preset |
| 自动更新进度表状态与 |
开发与测试
uv sync --extra dev
uv run ruff check src tests
uv run mypy
uv run pytestTool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
GitHub Private MCP Pack — access private repos, org data via OAuth. Complements the existing…
Create, deploy, and operate MCP servers directly from your GitHub repositories.
Create website projects, deploy GitHub sites and read logs/usage via remote OAuth MCP.
Unofficial GitHub MCP — wraps the GitHub public REST API (no auth required for public endpoints)
Related MCP Servers
- AlicenseBqualityDmaintenanceProvides tools for interacting with GitHub's API through the MCP protocol, allowing users to create repositories, push content, and retrieve user information.3MIT
- FlicenseNot gradedqualityDmaintenanceEnables managing GitHub repositories, files, and user information through MCP, with support for creating, updating, and deleting repository contents, as well as fetching user profiles.1-
- FlicenseNot gradedqualityCmaintenanceEnables GitHub repository operations (list/read files, create branches, commit files, open/list PRs) via an authless remote MCP server that keeps your GitHub token encrypted on Cloudflare, with access limited to allowed repositories.-
- FlicenseNot gradedqualityDmaintenanceEnables read-only browsing and querying of GitHub repositories, including listing repos, reading files, fetching READMEs, searching code, and viewing commit history via MCP.-