agentleFS
adampoitadampoit/ai/skills/gh/SKILL.md

gh

Skill2 starsChanged 13 days agoMITView on GitHub

Use the GitHub CLI (`gh`) for repository operations including PR and issue inspection, GitHub search, checks, and API calls. Use when a user asks for GitHub URLs, PR metadata, issue details, checks, or repository automation.

  • Commits and pushes

The file

We split this skill into the rules it gives an agent

10 rules. About 0 are common, 3 are distinctive, and 7 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈3

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 7

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Use gh for GitHub-related tasks.

    line 8
  2. Very specific:

    Prefer gh search for code/repo/issue/PR discovery.

    line 36
  3. Very specific:

    Use qualifiers to reduce noise: repo:, path:, language:, is:open, author:, label:

    line 64
  4. Distinctive:

    Start broad, then refine filters

    line 65
  5. Very specific:

    Use gh api when subcommands do not expose required fields.

    line 84
  6. Distinctive:

    Prefer machine-readable output for automation:

    line 90
  7. Very specific:

    Use --json where available

    line 92
  8. Very specific:

    Use gh api output with jq for deterministic extraction of fields like number, title, body, and url

    line 93
  9. Very specific:

    When the user provides a GitHub URL, parse owner/repo/number and fetch details with gh commands instead of browser scraping.

    line 97
  10. Distinctive:

    Default to read-only operations unless the user explicitly requests mutation.

    line 106

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Gh

Use gh for GitHub-related tasks.

gh pr view 123 --json number,title,body,commits,files,headRefName,url

Inspect PRs And Issues

View one PR as JSON:

gh pr view 123 --json number,title,body,commits,files,headRefName,url

List open PRs:

gh pr list --state open --json number,title,headRefName,url

View one issue as JSON:

gh issue view 456 --json number,title,body,comments,url

Search GitHub

Prefer gh search for code/repo/issue/PR discovery.

Code search:

gh search code "TODO repo:owner/repo path:src" --limit 20

Repository search:

gh search repos "topic:cli language:go" --limit 20 --json name,description,url

Issue search:

gh search issues "repo:owner/repo is:issue is:open label:bug" --limit 50 --json number,title,url,state,updatedAt

PR search:

gh search prs "repo:owner/repo is:pr is:open author:alice" --limit 50 --json number,title,url,state,updatedAt

Search tips:

  • Use qualifiers to reduce noise: repo:, path:, language:, is:open, author:, label:
  • Start broad, then refine filters
  • Combine with local search (rg) in checked-out repos when validating context

Checks And CI

View checks for a PR branch:

gh pr checks 123

View run details with links:

gh run list --limit 20

API And Automation

Use gh api when subcommands do not expose required fields.

gh api repos/:owner/:repo/pulls --method POST -f title='My PR' -f head='feature-branch' -f base='main'

Prefer machine-readable output for automation:

  • Use --json where available
  • Use gh api output with jq for deterministic extraction of fields like number, title, body, and url

URL Handling

When the user provides a GitHub URL, parse owner/repo/number and fetch details with gh commands instead of browser scraping.

Examples:

  • PR URL -> gh pr view <number> --repo <owner>/<repo> ...
  • Issue URL -> gh issue view <number> --repo <owner>/<repo> ...

Guardrails

Default to read-only operations unless the user explicitly requests mutation.

Read-only examples:

  • gh pr view, gh pr list, gh pr checks
  • gh issue view, gh search ..., gh run list, gh api GET calls

Mutating examples (require explicit user intent):

  • gh pr create, gh pr merge, gh pr close
  • gh issue create, gh issue edit, gh issue close
  • gh api POST/PATCH/DELETE calls

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.