Connects GitHub's official remote MCP server as a DSH plugin: stores the PAT in DSH's credential center (.credentials.yaml) via github_set_token, and exposes GitHub tools as mcp__github__*.
Install
# from npm (prebuilt)
dsh plugin --profile web add dsh-github-mcp
# from GitHub (first run asks for allowBuilds approval — follow the hint, retry)
dsh plugin --profile web add github:ZIye1208/dsh-github-mcp
Any plugin you install runs third-party code with your own permissions — it can read your files, use your credentials, and reach the network, and tool approvals don’t sandbox it. GitHub-sourced plugins also run build scripts at install time — pnpm blocks those until you allow them, so an install can stop with ERR_PNPM_GIT_DEP_PREPARE_NOT_ALLOWED or ERR_PNPM_IGNORED_BUILDS; dsh prints the exact key to add under allowBuilds in your profile’s pnpm-workspace.yaml, and the install works on the next run. Allowing a build is a trust decision: only install sources you trust, and pin a commit (github:owner/repo#sha).
README
Wraps GitHub MCP as a DSH plugin: connects to GitHub's official remote MCP Server, stores the token in the DSH credential center (
.credentials.yaml), lets the token be set through model tools, and exposes themcp__github__*tools. Comes with an optional panel plugindsh-github-mcp-hint(installed separately; see below).
📚 Features
- GitHub MCP connection: via
@deepseek-ai/dsh-mcp-clienttohttps://api.githubcopilot.com/mcp/; GitHub tools appear asmcp__github__*(search_repositories,list_pull_requests,create_pull_request,push_files,get_file_contents,merge_pull_request,add_issue_comment, … 40+ tools). - Token in the credential center: the GitHub PAT lives in DSH's
.credentials.yaml(refs.GITHUB_TOKEN), never in source or logs. - Model tools:
github_token_status— check whether the token is configured, its source, and writability.github_set_token— set/update the token (writes to the credential center and refreshes the current environment).
- Panel plugin
dsh-github-mcp-hint(optional, installed separately): theSettings → Plugins → GitHub MCPUI (examples + public repo stats).
🚀 Quick start
# 1. Install the main plugin
dsh plugin --profile web add dsh-github-mcp # npm (recommended)
# — or —
dsh plugin --profile web add github:ZIye1208/dsh-github-mcp # from GitHub
# To get the "Settings → Plugins → GitHub MCP" panel, install the panel plugin separately:
dsh plugin --profile web add dsh-github-mcp-hint
# 2. Set the token (just ask in chat)
# "set my GitHub token to ghp_xxx"
# 3. Restart DSH, then ask
# "is my GitHub token configured?" (github_token_status)
# "how many stars/downloads do my repos have" (mcp__github__* / panel)
⚙️ Install
npm (recommended, published to npmjs)
dsh plugin --profile web add dsh-github-mcp
Installing brings dsh-github-mcp-hint into node_modules (as a dependency), but DSH adds only "top-level dependencies" to a profile's bundles layer, so the panel plugin is not enabled automatically. To get the "Settings → Plugins → GitHub MCP" panel, run additionally:
dsh plugin --profile web add dsh-github-mcp-hint
This package is now published to the npmjs registry. Install with
dsh plugin --profile web add dsh-github-mcp.
GitHub
dsh plugin --profile web add github:ZIye1208/dsh-github-mcp
Local dev
Link the local path in the profile's package.json, add it to dsh.profile.bundles, then restart DSH.
🔑 Prerequisites
- DSH >= 0.1.x (uses the core
@deepseek-ai/dsh-mcp-client). - GitHub PAT: create at GitHub → Settings → Developer settings → Personal access tokens, with scopes
repo,read:org,read:packages.
🔐 Set the token (three ways)
A. Model tool (recommended)
Say: "set my GitHub token to ghp_xxxxxxxx" → the agent calls github_set_token, writing ~/.dsh/.credentials.yaml → refs.GITHUB_TOKEN.
B. Edit the credential center
Add to ~/.dsh/.credentials.yaml:
version: 1
refs:
GITHUB_TOKEN: ghp_xxxxxxxx
On the next DSH start the plugin bridges it into process.env.GITHUB_TOKEN.
C. Environment variable (legacy)
GITHUB_TOKEN=ghp_xxx in the launching shell. Note: if GITHUB_TOKEN is already in the environment it wins and is read-only — github_set_token will be refused. unset GITHUB_TOKEN first to use A/B.
⚠️ A token change needs a DSH restart — the mcp-client reads the token at startup (static header) and does not reconnect mid-run.
🧭 Usage
- Token status: ask "is my GitHub token configured?" →
github_token_status. - List/create PRs, push code, edit files, search code: use natural language; the model calls
mcp__github__*. Examples: "list all open PRs in owner/repo sorted by updated", "commit and push all changes on the current branch", "add a comment to owner/repo PR #123 and mark it ready for review", "search for keyword xxx in owner/repo". - Panel UI: Settings → Plugins → GitHub MCP (from
dsh-github-mcp-hint: random 4 of 30 examples, public repo stats).
🗑️ Uninstall / disable
Uninstall the whole plugin (incl. panel)
dsh plugin --profile web remove dsh-github-mcp
Uninstall only the panel (GitHub MCP unaffected)
dsh-github-mcp bundles dsh-github-mcp-hint (as a dependency). It is independently uninstallable:
- remove
dsh-github-mcp-hintfrom the profile'sdsh.profile.bundles; dsh plugin --profile web remove dsh-github-mcp-hint.
After that, github_token_status / github_set_token and every mcp__github__* keep working.
Disable only the panel (keep installed)
In cordis.patch.yml:
- id: dsh-github-mcp-hint
disabled: true
🧩 Architecture
token input ──(github_set_token)──► .credentials.yaml (refs.GITHUB_TOKEN)
│
▼ bridged at startup
process.env.GITHUB_TOKEN
│
▼ mcp-client reads at startup
Authorization: Bearer <token> ──► api.githubcopilot.com/mcp/
│
▼
registers mcp__github__* tools
dsh-github-mcp= GitHub MCP connection + token credential center.dsh-github-mcp-hint= panel UI (separate repo, uninstallable).- Why the bridge: DSH's credential store is never materialized into
process.env, so the plugin bridges it at startup for the mcp-client.
❓ Troubleshooting
- No
mcp__github__*: the token is unset or DSH wasn't restarted. Rungithub_token_status, then restart. github_set_tokenrefused:GITHUB_TOKENis in the launching env (read-only).unset GITHUB_TOKENfirst.serverName "github" already in use: you added a manualmcp-githubrow. Remove it; this plugin'scordis.patch.ymlowns that row.- Token change not taking effect: restart DSH.
- No "GitHub MCP" panel after
dsh-github-mcp: DSH adds only top-level dependencies to the bundles layer;dsh-github-mcp-hint(a transitive dependency) is not enabled automatically. Rundsh plugin --profile web add dsh-github-mcp-hint(or add it to the profile'sdsh.profile.bundles), then restart DSH.
📄 Repo relation
| Repo | Role |
|---|---|
ZIye1208/dsh-github-mcp |
GitHub MCP connection + token credential center (this plugin) |
ZIye1208/dsh-github-mcp-hint |
Panel UI (independent, uninstallable) |
License
Links
More in this category
zhu1090093659/dsh-web#packages/dsh-git-graph★ 9048
Git branch selector and Git graph for the dsh web GUI: switch branches and explore branch-lane and commit history from the conversation header.
Akimiya-z/codex-guard#dsh★ 133
Pre-submit pull-request hygiene checks inside DeepSeek Harness: scans the current diff for TODO leftovers, hardcoded secrets, and non-conventional commit subjects.
Cerbur/clutch-dsh#clutch-dsh-worktree★ 34
Adds a Worktree view to DSH Web UI that groups Sessions by Git worktree while keeping DSH as the source of truth.
lehhair/dsh-diff-viewer★ 26
PiUI-style diff viewer replacing the stock DiffBlock for write/edit tool calls.
DamonKoy/dsh-web-ui#dsh-git-graph★ 25
Git branch selector and Git graph in the conversation header of the dsh web GUI.
PerryLink/dsh-github★ 24
Official-grade GitHub CI integration: a composite action.yml, a polling PR review bot with idempotent inline comments and a status-check gate, plus PR/issues tools with every write gated by human approval.
Community comments
Comments are public GitHub Discussions. Loading them connects to GitHub and Giscus; a GitHub account is required to post.