gh-cli
The gh CLI is GitHub's official command line tool for interacting with GitHub repositories, issues, pull requests, and more. When needs to interact with GitHub repositories, issues, pull requests, and more, use this skill.
Install / Use
npx skills add benchflow-ai/skillsbench --skill gh-cliInstalls into whichever agent you are using.
SKILL.md
Installable skill definition
Quality Score
Category
Development & EngineeringSupported Platforms
Our assessment of gh-cli
gh-cli scores 92/100 on our quality scale, 807th of 4,653 Development & Engineering skills we index (top 18%).
Its SKILL.md is 6.3 KB long, well organised into 14 sections with 7 code examples: a thorough specification that gives an agent plenty to work with.
With 1,813 GitHub stars, it is one of the more widely adopted skills in the catalogue.
Maintenance, license and trust
- The repository was last updated about 2 months ago, so gh-cli is actively maintained.
- It is released under the Apache-2.0 license, a permissive license that allows use, modification and commercial use with attribution.
- Its trust signals score 100/100, with no cautions. These come from repository metadata, not a code audit — read the skill file before letting an agent act on it.
Safety scan
No issues foundOur scan of the whole file found no instruction hijacking, hidden characters, credential access, data exfiltration or destructive commands.
Automated pattern scan on 2026-10-02. It catches known dangerous patterns, not every risk — read a skill before letting an agent act on it.
gh-cli compared with similar skills
All 4 of these similar skills score higher than gh-cli; compare them before choosing.
| Skill | Score | Stars | Updated | Format |
|---|---|---|---|---|
| gh-cli (this skill)by benchflow-ai | 92 | 1.8k | 2mo ago | SKILL.md |
| Agent-Reachby Panniantong | 100 | 87.6k | 16d ago | CLAUDE.md |
| headroomby headroomlabs-ai | 100 | 74.3k | today | CLAUDE.md |
| ai-job-searchby MadsLorentzen | 100 | 44.7k | today | CLAUDE.md |
| claude-howtoby luongnv89 | 100 | 41.7k | 2d ago | CLAUDE.md |
Frequently asked questions
- How do I install gh-cli?
- Run
npx skills add benchflow-ai/skillsbench --skill gh-cli. The install tabs above show the steps for each supported agent. - Which AI agents does gh-cli work with?
- It is written for Universal, as a SKILL.md file. Other agents that read the same format can often use it too.
- Is gh-cli safe to use?
- Our scan of the whole file found no instruction hijacking, hidden characters, credential access, data exfiltration or destructive commands. It is Apache-2.0-licensed and scores 100/100 on trust signals. Skills are instructions an agent will follow, so read the file before installing it and do not approve commands you do not understand.
- Is gh-cli still maintained?
- The repository was last updated about 2 months ago, so gh-cli is actively maintained.
Skill content
View source on GitHubname: gh-cli description: "The gh CLI is GitHub's official command line tool for interacting with GitHub repositories, issues, pull requests, and more. When needs to interact with GitHub repositories, issues, pull requests, and more, use this skill." license: Proprietary. LICENSE.txt has complete terms
GitHub CLI (gh)
Work seamlessly with GitHub from the command line.
Usage
gh <command> <subcommand> [flags]
Core Commands
issue: Manage issues
pr: Manage pull requests
repo: Create, clone, fork, and view repositories
api: Make an authenticated GitHub API request
run: View details about workflow runs
Use gh <command> --help for more information about a command.
gh pr
Work with GitHub pull requests.
USAGE
gh pr <command> [flags]
CORE COMMANDS
checkout: Check out a pull request in git
checks: Show CI status for a single pull request
close: Close a pull request
comment: Create a new pr comment
create: Create a pull request
diff: View changes in a pull request
edit: Edit a pull request
list: List and filter pull requests in this repository
merge: Merge a pull request
ready: Mark a pull request as ready for review
reopen: Reopen a pull request
review: Add a review to a pull request
status: Show status of relevant pull requests
view: View a pull request
FLAGS
-R, --repo [HOST/]OWNER/REPO Select another repository using the [HOST/]OWNER/REPO format
INHERITED FLAGS
--help Show help for command
ARGUMENTS
A pull request can be supplied as argument in any of the following formats:
- by number, e.g. "123";
- by URL, e.g. "https://github.com/OWNER/REPO/pull/123"; or
- by the name of its head branch, e.g. "patch-1" or "OWNER:patch-1".
EXAMPLES
$ gh pr checkout 353
$ gh pr create --fill
$ gh pr view --web
LEARN MORE
Use 'gh <command> <subcommand> --help' for more information about a command.
Read the manual at https://cli.github.com/manual
gh issue
Work with GitHub issues.
USAGE
gh issue <command> [flags]
CORE COMMANDS
close: Close issue
comment: Create a new issue comment
create: Create a new issue
delete: Delete issue
edit: Edit an issue
list: List and filter issues in this repository
reopen: Reopen issue
status: Show status of relevant issues
transfer: Transfer issue to another repository
view: View an issue
FLAGS
-R, --repo [HOST/]OWNER/REPO Select another repository using the [HOST/]OWNER/REPO format
INHERITED FLAGS
--help Show help for command
ARGUMENTS
An issue can be supplied as argument in any of the following formats:
- by number, e.g. "123"; or
- by URL, e.g. "https://github.com/OWNER/REPO/issues/123".
EXAMPLES
$ gh issue list
$ gh issue create --label bug
$ gh issue view --web
LEARN MORE
Use 'gh <command> <subcommand> --help' for more information about a command.
Read the manual at https://cli.github.com/manual
gh repo
Work with GitHub repositories.
USAGE
gh repo <command> [flags]
CORE COMMANDS
archive: Archive a repository
clone: Clone a repository locally
create: Create a new repository
delete: Delete a repository
edit: Edit repository settings
fork: Create a fork of a repository
list: List repositories owned by user or organization
rename: Rename a repository
sync: Sync a repository
view: View a repository
INHERITED FLAGS
--help Show help for command
ARGUMENTS
A repository can be supplied as an argument in any of the following formats:
- "OWNER/REPO"
- by URL, e.g. "https://github.com/OWNER/REPO"
EXAMPLES
$ gh repo create
$ gh repo clone cli/cli
$ gh repo view --web
Search Query Syntax
The --search flag uses GitHub search syntax. Full documentation: https://docs.github.com/en/search-github/getting-started-with-searching-on-github/understanding-the-search-syntax
Comparison Operators
| Query | Description | Example |
|-------|-------------|---------|
| >n | Greater than | stars:>1000 |
| >=n | Greater than or equal | topics:>=5 |
| <n | Less than | size:<10000 |
| <=n | Less than or equal | stars:<=50 |
Range Queries
| Query | Description | Example |
|-------|-------------|---------|
| n..n | Between range | stars:10..50 |
| n..* | Greater than or equal | stars:10..* (same as >=10) |
| *..n | Less than or equal | stars:*..10 (same as <=10) |
Date Queries
Date format: YYYY-MM-DD (ISO8601). Optional time: YYYY-MM-DDTHH:MM:SS+00:00
| Query | Example |
|-------|---------|
| >YYYY-MM-DD | created:>2024-04-29 — after April 29, 2024 |
| >=YYYY-MM-DD | created:>=2024-04-01 — on or after April 1, 2024 |
| <YYYY-MM-DD | pushed:<2024-07-05 — before July 5, 2024 |
| <=YYYY-MM-DD | created:<=2024-07-04 — on or before July 4, 2024 |
| YYYY-MM-DD..YYYY-MM-DD | created:2024-04-30..2024-07-04 — date range |
| YYYY-MM-DD..* | created:2024-04-30..* — on or after date |
| *..YYYY-MM-DD | created:*..2024-07-04 — on or before date |
Exclude Results
Prefix qualifier with - to exclude:
| Query | Example |
|-------|---------|
| -QUALIFIER | stars:>10 -language:javascript — exclude JavaScript repos |
| NOT | hello NOT world — has "hello" but not "world" |
Usernames
| Query | Description |
|-------|-------------|
| author:USERNAME | Filter by specific user |
| author:@me | Filter by current user |
| assignee:@me | Assigned to current user |
Queries with Whitespace
Use quotation marks for multi-word values:
label:"bug fix"— label with spacecats NOT "hello world"— exclude phrase
JSON Output
Common fields for --json:
PR:
additions
assignees
author
baseRefName
body
changedFiles
closed
closedAt
comments
commits
createdAt
deletions
files
headRefName
headRepository
headRepositoryOwner
id
isCrossRepository
isDraft
labels
maintainerCanModify
mergeCommit
mergeStateStatus
mergeable
mergedAt
mergedBy
milestone
number
potentialMergeCommit
projectCards
reactionGroups
reviewDecision
reviewRequests
reviews
state
statusCheckRollup
title
updatedAt
url
Issue:
close
comment
create
delete
edit
list
reopen
status
transfer
view
Related Skills
Agent-Reach
87.6kGive your AI agent eyes to see the entire internet. Read & search Twitter, Reddit, YouTube, GitHub, Bilibili, XiaoHongShu — one CLI, zero API fees.
headroom
74.3kCompress tool outputs, logs, files, and RAG chunks before they reach the LLM. 20% fewer tokens for coding agents, 60-95% fewer tokens for JSON, same answers. Library, proxy, MCP server.
ai-job-search
44.7kThe job search that runs on your machine. AI job application framework built on Claude Code: evaluate postings, tailor CVs, write cover letters, prep interviews. Fork it and own it.
claude-howto
41.7kA visual, example-driven guide to Claude Code — from basic concepts to advanced agents, with copy-paste templates that bring immediate value.
Languages
Trust signals
From repository metadata: license, adoption, age and documentation. Not a code audit — see the Safety scan above for what the skill file itself contains.
