mcpField
G
github

github

github.com/conorkenn开发0139 次安装38 周前更新
代码仓库

关于 github

通过 AI 助手查询和管理 GitHub 仓库的 OpenClaw 技能,支持发现仓库、查看详情、检查 CI 状态、创建议题和仓库,以及查看近期提交。

主要功能

  1. 01列出并搜索仓库
  2. 02获取仓库详情
  3. 03检查 CI/CD 状态
  4. 04创建议题和仓库
  5. 05查看近期提交

适用场景

  1. 01按语言或筛选条件查找仓库
  2. 02查看仓库的 CI 状态
  3. 03为反馈的错误创建议题
  4. 04检查近期提交活动

安装

复制下面的命令,在终端中运行。

$npx skills add https://github.com/conorkenn/openclaw-github-assistant --skill github

安装后在 Claude Code 中输入/github确认已加载。

包含的文件

除 SKILL.md 外,安装时一起下载的参考资料和脚本。

.gitignore
README.md
LICENSE
package-lock.json
package.json
tsconfig.json
dist/
api.d.ts
api.d.ts.map
api.js
index.d.ts
api.js.map
index.d.ts.map
index.js
index.js.map
types.d.ts
types.js
types.d.ts.map
types.js.map
src/
types.ts
api.ts
index.ts

详细介绍

GitHub 集成技能

直接通过 AI 助手查询和管理 GitHub 仓库。

功能

功能描述
list_repos使用筛选条件列出你的仓库
get_repo获取特定仓库的详细信息
check_ci_status检查 CI/CD 流水线状态
create_issue在仓库中创建新 issue
create_repo创建新仓库
search_repos搜索你的仓库
get_recent_activity获取近期提交

用法

You: List my Python repos
Bot: [lists your Python repositories]

You: Check CI status on my main project
Bot: [shows CI/CD status]

You: Create an issue about the bug
Bot: [creates the issue]

设置

1. 生成 GitHub 个人访问令牌
  1. 前往 https://github.com/settings/tokens
  2. 点击“Generate new token (classic)”
  3. 名称:openclaw-github-skill
  4. 权限范围:repo(必需)、read:user(可选)
  5. 复制令牌
2. 配置凭据

选项 A:环境变量(推荐)

启动 OpenClaw 前设置环境变量:

export GITHUB_TOKEN="ghp_your_token_here"
export GITHUB_USERNAME="your_github_username"

选项 B:OpenClaw 配置

添加到 ~/.openclaw/openclaw.json:

{
  "github": {
    "token": "ghp_your_token_here",
    "username": "your_username"
  }
}
3. 重启 OpenClaw
openclaw gateway restart

安全说明

⚠️ 保护你的令牌:

  • 切勿将令牌提交到 git 或公开分享
  • 使用所需的最小权限范围(私有仓库使用 repo,仅限公共仓库使用 public_repo)
  • 如果怀疑令牌已泄露,请轮换令牌
  • 在生产环境中使用时,可考虑使用密钥管理器

⚠️ 最佳实践:

  • 不要在共享计算机的 shell 配置文件(~/.zshrc)中存储令牌
  • 对于本地开发,可以使用环境变量
  • 对于生产环境,请使用平台的密钥/凭据存储

速率限制

  • 未经身份验证的请求:每小时 60 次
  • 已通过身份验证的请求:每小时 5,000 次

要求

  • OpenClaw 网关正在运行
  • 具有适当权限范围的 GitHub 个人访问令牌

评论

支持 Markdown