用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/L-LesterYu/OpenClaw-hot-skills-zh --skill github命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
基于 SOC 职业分类
正在显示 SKILL.md
| name | github |
| description | 使用 `gh` CLI 与 GitHub 交互。使用 `gh issue`、`gh pr`、`gh run` 和 `gh api` 处理问题、PR、CI 运行和高级查询。 |
使用 gh CLI 与 GitHub 交互。当不在 git 目录中时,始终指定 --repo owner/repo,或直接使用 URL。
检查 PR 的 CI 状态:
gh pr checks 55 --repo owner/repo
列出最近的 workflow 运行:
gh run list --repo owner/repo --limit 10
查看运行记录并查看哪些步骤失败:
gh run view <run-id> --repo owner/repo
仅查看失败步骤的日志:
gh run view <run-id> --repo owner/repo --log-failed
gh api 命令对于访问其他子命令无法获取的数据非常有用。
获取 PR 的特定字段:
gh api repos/owner/repo/pulls/55 --jq '.title, .state, .user.login'
大多数命令支持 --json 以获得结构化输出。你可以使用 --jq 进行过滤:
gh issue list --repo owner/repo --json number,title --jq '.[] | "\(.number): \(.title)"'
列出仓库的 issues:
gh issue list --repo owner/repo
创建新 issue:
gh issue create --repo owner/repo --title "标题" --body "描述"
查看 issue 详情:
gh issue view 123 --repo owner/repo
创建 PR:
gh pr create --repo owner/repo --title "PR 标题" --body "PR 描述"
查看 PR 详情:
gh pr view 55 --repo owner/repo
合并 PR:
gh pr merge 55 --repo owner/repo
查看特定的 workflow 运行:
gh run view <run-id> --repo owner/repo
重新运行失败的 workflow:
gh run rerun <run-id> --repo owner/repo
克隆仓库:
gh repo clone owner/repo
创建新仓库:
gh repo create repo-name --public
查看仓库信息:
gh repo view owner/repo
确保已安装 GitHub CLI (gh):
# macOS
brew install gh
# Linux
# 参考: https://github.com/cli/cli/blob/trunk/docs/install_linux.md
# Windows
winget install GitHub.cli
首次使用需要进行身份认证:
gh auth login
--help 标志查看任何命令的详细帮助--json 和 --jq 进行灵活的数据提取和处理--quiet 或 --silent 减少输出gh api 访问 GitHub REST API 的任何端点