github-cli
Skill56 starsChanged 34 days agoApache-2.0View on GitHub
Helper skill for GitHub operations in this repo; use it when another workflow needs gh for PRs, issues, review threads, checks, Actions runs, or job logs — including logs from a job that is still running.
25 other projects use a version of this.
Adopted by
Most recently taken up by
- himkt/configtheir own version, first seen Nov 7, 2026
- rogue-dev-studio/ai-agents-roguetheir own version, first seen Nov 1, 2026
- kuailexiaozixin/githubtheir own version, first seen Oct 24, 2026
- Anish29801/cursor-plugin-github-clitheir own version, first seen Oct 20, 2026
- danilolucasmd/skillstheir own version, first seen Oct 19, 2026
- garri333/Skillstheir own version, first seen Oct 11, 2026
Used with
Projects with it also use terraform, codex-cli and 3 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
ihiteshguptaSkillterraform
Expert in Infrastructure as Code with Terraform. Use for creating, managing, and versioning infrastructure across cloud providers.
Also in 3 projects that use this
garri333Skillcodex-cli
OpenAI Codex CLI mastery skill for installation, authentication, terminal commands, code generation from natural language, file editing, project scaffolding, and IDE integrations. Covers GPT-5.2 Instant/Thinking tiers and shell/container execution modes.
Also in 3 projects that use this
PostHogSkillkarpathy-guidelines
Behavioral guidelines to reduce common LLM coding mistakes. Use when writing, reviewing, or refactoring code to avoid overcomplication, make surgical changes, surface assumptions, and define verifiable success criteria. Based on https://github.com/multica-ai/andrej-karpathy-skills.
Also in 3 projects that use this
MicrosoftSkillcaveman
Ultra-compressed response style that reduces output token count while preserving technical accuracy, with intensity levels and auto-clarity safety rules
Also in 3 projects that use this
BlockSkillfrontend-design
Create distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
Also in 4 projects that use this
Other versions25 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 25
- himkt/config★ 40same name
- georgekhananaev/claude-skills-vault★ 28same name
- doug-skinner/github-cli-claude-skill★ 10same name
- abdullahkhawer/devops-skills★ 8same name
- jonhill90/skills★ 8same name
- trotsky1997/My-Claude-Agent-Skills★ 7same name
- magnusrodseth/dotfiles★ 3same name
- shalomb/agent-skills★ 3same name
- aaronflorey/agent-skills★ 2same name
- chief-builder/cli-vs-mcp★ 2same name
15 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository35 other files it gives its agents.
- AGENTS.mdAGENTS.md
- .github/AGENTS.mdAGENTS.md
- android/CLAUDE.mdCLAUDE.md
- CLAUDE.mdCLAUDE.md
- .github/CLAUDE.mdCLAUDE.md
- ios/CLAUDE.mdCLAUDE.md
- auto-mobile-code-reviewSkill
- ci-failure-triageSkill
- github-pr-feedbackSkill
- ios-swift-ciSkill
- node-prepushSkill
- prepush-androidSkill
- shell-prepushSkill
- android-gradlewSkill
- auto-mobile-code-reviewSkill
- bun-tasksSkill
- check-ciSkill
- ci-failure-triageSkill
- dead-codeSkill
- device-session-lifecycleSkill
- fan-out-fan-inSkill
- github-pr-feedbackSkill
- ios-swift-ciSkill
- manual-testSkill
- node-prepushSkill
- observeSkill
- pr-analysisSkill
- prepush-androidSkill
- push-my-prsSkill
- push-prSkill
- researchSkill
- shell-prepushSkill
- ship-issueSkill
- testSkill
- validateSkill
The file
We split this skill into the rules it gives an agent
5 rules. 0 are common, 3 are distinctive, and 2 are very specific to this project.
0
Common
Most of the 19 edited versions we read keep these.
3
Distinctive
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 11
Prefer gh pr view|list|create|edit and gh issue list|view.
- Very specific: line 14
Write long output to scratch/ and summarize.
- Distinctive: line 19
No single endpoint returns all PR feedback.
- Distinctive: line 79
Only resolve on a PR we authored and are actively working, once the finding is genuinely handled — fixed in a pushed commit, or verified …
- Distinctive: line 179
Every red result is PR-caused, pre-existing on main, transient/infrastructure, or
“Common” is measured: kept by at least 6 in 10 of the 19 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
GitHub CLI Usage
Shared dependency for check-ci, github-pr-feedback, auto-mobile-code-review,
pr-analysis, push-pr, and push-my-prs.
- Prefer
gh pr view|list|create|editandgh issue list|view. - Reach for
gh api/GraphQL only where the subcommands fall short — review-thread resolution state and live job logs are the two cases that matter here. - Write long output to
scratch/and summarize. Job logs run 100KB+; never let one into the conversation whole.
PR feedback: four separate surfaces
No single endpoint returns all PR feedback. Collect all four, paginated, or miss whole categories:
gh api --paginate "repos/kaeawc/auto-mobile/issues/<PR>/comments?per_page=100" # conversation
gh api --paginate "repos/kaeawc/auto-mobile/pulls/<PR>/reviews?per_page=100" # review verdicts
gh api --paginate "repos/kaeawc/auto-mobile/pulls/<PR>/comments?per_page=100" # inline (no resolution state)
# review threads — the only source of resolution state — belowThese three return top-level JSON arrays, and --paginate merges the pages into one flat
array, so redirecting to a file and parsing it with jq is safe. Verified on gh 2.96 against
PR #4117 with per_page=2: five GET requests, one top-level document, element count matching
the unpaginated result. (The gh api manual describes pages as separate documents — true for
GraphQL and for object-shaped responses, but not for these array endpoints on this version. If
you are on an older gh, re-check before relying on it.) Do not add --slurp
here: on an array endpoint it produces an array of pages ([[…],[…]]), and it is rejected
outright when combined with --jq (the --slurp option is not supported with --jq or
--template). GraphQL is the opposite case — see below.
Scope everything to the PR's headRefOid; after any push, re-collect from the new head. For
the triage workflow — ledger, dispositions, resolution conditions — use github-pr-feedback.
This is just the mechanics.
Review threads: resolution state
GET /pulls/{n}/comments and gh pr view --json comments return bodies but not whether a
thread is resolved; that lives only in GraphQL. Collect threads through the tested helper:
scripts/ci/pr-review-threads.sh <PR> --unresolved-onlyIt paginates review threads, emits one clean JSON array, and fails closed rather than returning a
partial feedback ledger. Do not replace it with a saved gh api graphql --paginate response:
GraphQL emits one JSON document per page, unlike the REST array endpoints above.
--paginate advances the outer reviewThreads connection only. The nested
comments(first:20) is a separate connection: a thread with more replies than that silently
truncates, and the later replies are exactly where a rebuttal or fix-evidence lives. For a
thread you are about to resolve on the strength of its discussion, read the full comment list
from REST instead, which paginates properly:
gh api --paginate "repos/kaeawc/auto-mobile/pulls/<PR>/comments?per_page=100" \
--jq '.[] | select(.in_reply_to_id == <root_comment_id> or .id == <root_comment_id>)
| "\(.user.login): \(.body)"'isOutdated means the anchored line changed, not that the finding was addressed — judge
outdated threads on content.
Resolving needs only the thread's PRRT_… id:
gh api graphql -f query='
mutation($id:ID!){ resolveReviewThread(input:{threadId:$id}){ thread{ isResolved } } }' \
-F id=<PRRT_…>Only resolve on a PR we authored and are actively working, once the finding is genuinely handled — fixed in a pushed commit, or verified and declined. Both count: resolving claims the thread is dealt with, not that the reviewer was right. Leave it open only when you could not determine whether the finding is real. Replying instead takes the comment id, not the thread id:
gh api repos/kaeawc/auto-mobile/pulls/<PR>/comments/<comment_id>/replies -f body='…'Bot findings
chatgpt-codex-connector[bot] encodes severity as a body badge (P1 Badge/P2 Badge/P3 Badge):
gh api repos/kaeawc/auto-mobile/pulls/<PR>/comments --paginate \
--jq '.[] | select(.user.login|test("codex"))
| {id, path, line, sev: (.body|capture("P(?<n>[123]) Badge").n), body: .body[0:400]}'P1 claims to block. Codex is usually right about mechanism and sometimes wrong about
reachability — verify before acting and equally before dismissing, and keep those two judgements
apart: a false mechanism often arrives attached to a good suggestion, so evaluate the proposed
change on its own reasoning before rejecting it. Refuting also carries the higher burden than
accepting, since a wrong rejection leaves a live bug. When you do decline, report the reason
in-session and resolve the thread; do not post a reply. github-pr-feedback and
auto-mobile-code-review both forbid posting, and a decline is not an exception.
Checks
gh pr checks <PR> --json name,state,bucket,linkBranch on bucket: pass, fail, pending, skipping, cancel. Only fail is a
failure. A cancelled check on the head SHA is usually a superseded run from a rapid push,
but it can still wedge the green-main ruleset — re-run it rather than debugging code.
Cross-check the head SHA's check-runs, where duplicates surface:
# filter defaults to `latest`, which hides exactly the stale duplicate you are looking for.
gh api --paginate "repos/kaeawc/auto-mobile/commits/<HEAD_SHA>/check-runs?per_page=100&filter=all" \
--jq '.check_runs[] | "\(.name)\t\(.status)\t\(.conclusion // "-")\t\(.completed_at)"' | sortThe same name twice with different conclusions — a cancelled older run beside a successful
newer one — is what parks automerge; take the newest. An empty legacy combined status is
inconclusive, not green, and a queued/in_progress job is never implicitly green.
Actions: runs, jobs, logs
Navigate run → jobs → one job's log; never download a whole run to read one failure.
gh run list --branch <branch> --limit 20 --json databaseId,name,status,conclusion,headSha
gh api repos/kaeawc/auto-mobile/actions/runs/<RUN_ID>/jobs \
--jq '.jobs[] | "\(.id)\t\(.status)\t\(.conclusion // "-")\t\(.name)"'While the run is still going
gh run view <run> --log refuses on an in-progress run (run … is still in progress; logs will
be available when it is complete), and the per-job log endpoint 404s (BlobNotFound) for an
unfinished job. Neither means waiting for the whole matrix — a finished job's log is readable
immediately, even while siblings run:
gh api repos/kaeawc/auto-mobile/actions/jobs/<JOB_ID>/logsSo the live-triage loop is: poll the run's jobs, and pull each job's log the moment its
status is completed with conclusion: failure. For a job still executing, step state
locates it with no log fetch at all:
gh api repos/kaeawc/auto-mobile/actions/jobs/<JOB_ID> \
--jq '.name, (.steps[] | " \(.number)\t\(.status)\t\(.conclusion // "-")\t\(.name)")'gh run watch <RUN_ID> --exit-status waits to completion without hand-polling.
Extracting the failure
Fetch once to a file, then search — don't re-request per grep:
gh api repos/kaeawc/auto-mobile/actions/jobs/<JOB_ID>/logs > scratch/job-<JOB_ID>.log
grep -nE '##\[error\]|FAIL|✗|Error:|error:' scratch/job-<JOB_ID>.log | head -40##[error] is the Actions-native marker and the highest-signal pattern. gh run view <RUN_ID>
--log-failed works only once the whole run finishes; --job <JOB_ID> --log-failed narrows
to one job. gh api --follow does not exist in the installed CLI — use --paginate. If the log
is truncated or lacks the failure body, list the run's artifacts and read the relevant one; when
gh run download returns an authorization error, report that exact blocker rather than
inferring a cause.
Classify before you fix
Every red result is PR-caused, pre-existing on main, transient/infrastructure, or
unproven — grounded in the job log, changed paths, and current origin/main. A failure in a
subsystem the diff never touches is usually not this PR's. Re-run only on evidence of
transience; never change code for an unrelated or unproven failure.
Portability
CI runs macOS legs and this repo lints its own scripts for BSD/GNU portability. Avoid GNU-only
invocations in anything you write down: grep -P/grep -oP, sed -i without an argument,
readlink -f, mapfile, date -d. Use grep -oE, sed -i '', and awk.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

