← Back to list
List Pull Requests (
View Pull Request (
Comment on Pull Request (
Close / Reopen Pull Request (
List Issues (
View Issue (
Comment on Issue (
Close or Reopen Issue (

gh-pr-issue
by MHolmes91
A collection of agents, sub-agents, commands, and skills (using openskills) to enhance an opencode agent's ability to work with GitHub
⭐ 3🍴 0📅 Dec 26, 2025
SKILL.md
name: gh-pr-issue description: Keep pull requests and issues healthy using gh CLI (list, view, comment, close).
When to Use
Invoke this skill when triaging review queues, summarizing checks, or updating GitHub issues. It wraps gh pr and gh issue commands so you can stay on top of reviews without leaving Opencode.
Prerequisites
ghCLI authenticated (gh auth login --scopes repo,workflow).jqinstalled for JSON parsing.- Environment variables (ask for them if absent):
GITHUB_REPOSITORYDEFAULT_BRANCH
Pull Request Procedures
List Pull Requests (/pr-list)
- Command template:
gh pr list --repo "$GITHUB_REPOSITORY" \ --state ${STATE:-open} \ ${LABEL:+--label "$LABEL"} \ ${SEARCH:+--search "$SEARCH"} \ --limit ${LIMIT:-20} \ --json number,title,author,reviewDecision,updatedAt,url - Pipe to
jq '.'. - Highlight numbers, titles, reviewDecision, and last updated timestamps.
View Pull Request (/pr-checks, /pr-open)
- Fetch metadata + checks:
gh pr view "$PR_NUMBER" --repo "$GITHUB_REPOSITORY" \ --json number,title,author,baseRefName,headRefName,isDraft,mergeable,reviewDecision,checks - Summarize failing checks with names, status, and URLs.
- To open in browser, run
gh pr view "$PR_NUMBER" --repo "$GITHUB_REPOSITORY" --web(gh will launch the default browser; echo the URL when possible).
Comment on Pull Request (/pr-comment)
- Ensure a comment body exists; request it if missing.
- Run
gh pr comment "$PR_NUMBER" --repo "$GITHUB_REPOSITORY" --body "$BODY". - Share the resulting comment URL from gh output.
Close / Reopen Pull Request (/pr-close)
- Optional: leave a note explaining why the PR is closing.
- If deleting the branch, append
--delete-branch. - Command:
[ -n "$BODY" ] && gh pr comment "$PR_NUMBER" --repo "$GITHUB_REPOSITORY" --body "$BODY" gh pr close "$PR_NUMBER" --repo "$GITHUB_REPOSITORY" ${DELETE_BRANCH:+--delete-branch} - Report final state.
Issue Procedures
List Issues (/issue-list)
- Command template:
gh issue list --repo "$GITHUB_REPOSITORY" \ --state ${STATE:-open} \ ${LABEL:+--label "$LABEL"} \ ${SEARCH:+--search "$SEARCH"} \ --limit ${LIMIT:-20} \ --json number,title,author,assignees,updatedAt,url - Use
jq '.'and summarize.
View Issue (/issue-view)
- Fetch metadata:
gh issue view "$ISSUE_NUMBER" --repo "$GITHUB_REPOSITORY" \ --json number,title,state,body,labels,assignees,url - Surface body excerpt, labels, assignees, and share the URL.
Comment on Issue (/issue-comment)
- Confirm comment body.
- Run
gh issue comment "$ISSUE_NUMBER" --repo "$GITHUB_REPOSITORY" --body "$BODY". - Return confirmation output.
Close or Reopen Issue (/issue-close, /issue-reopen)
- For closing:
- Optionally comment with context first.
- Run
gh issue close "$ISSUE_NUMBER" --repo "$GITHUB_REPOSITORY".
- For reopening:
- Optionally state the reason.
- Run
gh issue reopen "$ISSUE_NUMBER" --repo "$GITHUB_REPOSITORY".
- Confirm the resulting state.
Safety Checks
- Never mutate PRs/issues outside
GITHUB_REPOSITORY. - Validate required arguments (PR/issue numbers, comment bodies) before running gh commands.
- When summarizing checks, focus on failing or pending contexts to avoid noisy output.
Score
Total Score
65/100
Based on repository quality metrics
✓SKILL.md
SKILL.mdファイルが含まれている
+20
○LICENSE
ライセンスが設定されている
0/10
✓説明文
100文字以上の説明がある
+10
○人気
GitHub Stars 100以上
0/15
✓最近の活動
3ヶ月以内に更新
+5
○フォーク
10回以上フォークされている
0/5
✓Issue管理
オープンIssueが50未満
+5
✓言語
プログラミング言語が設定されている
+5
✓タグ
1つ以上のタグが設定されている
+5
Reviews
💬
Reviews coming soon

