跳至正文
OpenAgentSkill
浏览已开放 · 目录记录日期 2026-11-21 · 自动更新和账户服务暂时关闭。
开发与测试

github-issues

Use gh CLI to view, triage, fix, link, create, or close GitHub Issues.

dannote · 已有静态检查记录

安装与使用

运行命令前先阅读来源与依赖说明。复制命令不会自动安装或执行。

npx skills add dannote/dot-pi --skill github-issues

技能说明


name: github-issues description: Use gh CLI to view, triage, fix, link, create, or close GitHub Issues.

GitHub Issues Workflow

Markdown bodies: never inline multiline text

Never pass multiline Markdown through --body "...". Shell quoting can leak literal \n into GitHub.

Always write Markdown to a temp file and use --body-file:

cat > /tmp/body.md <<'EOF'
## Summary

- ...

## Tests

- `...`
EOF

gh pr create --body-file /tmp/body.md
# or
gh pr edit <number> --body-file /tmp/body.md
# or
gh issue create --body-file /tmp/body.md

Review handoff

For PR inspection, use the pr-review skill. This skill handles GitHub issue and PR mechanics such as reading templates, using --body-file for multiline Markdown, and checking existing comments before closing or posting.

View issue

gh issue view <number>

Create issue safely

For non-trivial bodies, always write the draft to a temp file first. Do not inline long Markdown with shell quoting.

cat > /tmp/issue.md <<'EOF'
### What happened?

...
EOF

gh issue create --repo OWNER/REPO --title "Short title" --body-file /tmp/issue.md

Before creating issues in someone else's repo, check templates/contributing docs and keep the report concise.

gh api repos/OWNER/REPO/contents/.github/ISSUE_TEMPLATE --jq '.[].name'
gh api repos/OWNER/REPO/contents/CONTRIBUTING.md --jq .content | base64 --decode

If gh issue create prompts for confirmation, review the preview carefully before accepting.

Link issues in commits, changelogs, releases

  • Commits: fix: description (#1) or fix: description (fixes #1) — auto-closes on merge to default branch
  • Changelog: ([#1](https://github.com/owner/repo/issues/1))
  • Release notes: fixes #1 — does NOT auto-close, must close manually

Public replies

Use the maintainer-reply skill before drafting or posting issue and PR replies. Read the conversation first; do not apply a generic thank-you or mention a fix version when it is unknown or irrelevant.

Close with comment

When closing with a reply, mention the fix version when known and thank the reporter when appropriate to the conversation:

gh issue close <number> --comment "Fixed in v1.2.3. Thanks for the report!"

Test fixes before closing

For npm packages, simulate fresh install:

npm pack --pack-destination /tmp/
cd /tmp && mkdir test && cd test
echo '{"name":"test"}' > package.json
bun add /tmp/package-name-1.0.0.tgz
./node_modules/.bin/command --help