gh skill
✓ VerifiedManage GitHub repositories, issues, pull requests, releases, workflows, and gists using the gh command line tool.
- GitHub stars
- 1,703
- Files
- 1
- Last commit
- Nov 11, 2026
- License
- Apache-2.0
- Allowed tools
- —
What does the gh skill do?
gh manages GitHub repositories, issues, pull requests, releases, workflows, and gists using the gh command line tool.
Summary generated from the skill's SKILL.md.
About the gh skill
Managing GitHub repositories, issues, and pull requests through a command line interface is what this skill enables. Developers can use it to automate repository creation, fork projects, and handle the entire lifecycle of pull requests including reviews and merges. It also provides direct access to GitHub Actions by allowing users to run, list, and monitor workflows.
An agent should load this skill when it needs to perform administrative tasks on GitHub or interact with code hosting features. It relies on the gh command line tool and executes commands via the bash tool. When working within a local repository context, the agent sets the current working directory to the target checkout. The skill can also manage gists and handle the installation or updating of agent skills using the gh skill command.
Authentication is handled through GH_TOKEN or GITHUB_TOKEN, which take precedence over stored credentials. Users can also manage software releases by creating tags and uploading files. The tool supports advanced scripting by combining the --json flag with jq for structured data processing.
What an agent can do with it
- 1Automate pull request managementAn agent can create, review, and merge pull requests to streamline code contributions.
- 2Monitor CI/CD workflowsDevelopers can use the skill to trigger and track the status of GitHub Actions.
- 3Manage software releasesThe skill allows for the creation of new releases and the uploading of associated files.
- 4Install new agent skillsUsers can search for and install specific agent skills directly into their directory.
Written from the skill's SKILL.md. Every use case is checked against a quote from it.
How to install the gh skill
Each command copies the skill folder into the client's skills directory. Restart the client or start a new session to load it.Install the gh skill in Claude Code
~/.claude/skills/gh/SKILL.md
$ npx degit bubbuild/bub/src/skills/gh ~/.claude/skills/ghInstall the gh skill in Claude Code (project)
.claude/skills/gh/SKILL.md
$ npx degit bubbuild/bub/src/skills/gh .claude/skills/ghInstall the gh skill in Codex
~/.agents/skills/gh/SKILL.md
$ npx degit bubbuild/bub/src/skills/gh ~/.agents/skills/ghInstall the gh skill in Gemini CLI
~/.gemini/skills/gh/SKILL.md
$ npx degit bubbuild/bub/src/skills/gh ~/.gemini/skills/ghInstall the gh skill in Claude.ai
npx degit bubbuild/bub/src/skills/gh gh && zip -r gh.zip gh # claude.ai → Customize → Skills → + → Create skill → Upload a skill → gh.zip
Automated checks
Ran Nov 15, 2026Full report →Passed our automated checks. That is not a security audit: read the scripts before you let an agent run them. How checks work
- Source repository linked and reachablebubbuild/bub/src/skills/gh is public and reachablegithub.com/bubbuild/bub/tree/HEAD/src/skills/gh ↗Pass
- Open source license (OSI)Apache-2.0spdx.org/licenses/Apache-2.0.html ↗Pass
- Commit or release in the last yearLast commit 2026-11-11github.com/bubbuild/bub/commits ↗Pass
- No download-and-run or credential theft in scriptsNo scripts in the skill folderPass
- No hidden instructions in SKILL.mdNo override phrases, safeguard switches, credential requests or hidden charactersgithub.com/bubbuild/bub/blob/HEAD/src/skills/gh/SKILL.md ↗Pass
- Pre-approved tools are scopedNo pre-approved tools; the agent asks before using onegithub.com/bubbuild/bub/blob/HEAD/src/skills/gh/SKILL.md ↗Pass
- SKILL.md follows the Agent Skills formatValid name and description; says when to use it; 105 linesgithub.com/bubbuild/bub/blob/HEAD/src/skills/gh/SKILL.md ↗Pass
SKILL.md
View on GitHubGitHub CLI (gh) Skill
Interact with GitHub using the gh command line tool.
Run commands with Bub's bash tool, setting cwd to the target checkout when using local repository context. If it returns a running shell ID, collect the result with bash.output before retrying the command.
Prerequisites
Use the authentication source specified by the user or workspace. For github.com, GH_TOKEN takes precedence over GITHUB_TOKEN, and both override stored gh credentials.
Check authentication:
gh auth status
If not authenticated, report the blocker; do not silently switch credentials. Run interactive login only when the user requests authentication setup:
gh auth login
Repository Operations
gh repo create <name> [--public|--private]
gh repo clone <owner/repo>
gh repo fork <owner/repo>
gh repo view [owner/repo]
gh repo list [owner]
Issue Operations
gh issue create --title "Title" --body "Body"
gh issue list [--state open|closed]
gh issue view <number>
gh issue close <number>
gh issue comment <number> --body "Comment"
Pull Request Operations
gh pr create --title "Title" --body "Body"
gh pr list [--state open|closed]
gh pr view <number>
gh pr checkout <number>
gh pr merge <number>
gh pr review <number> --approve
Release Operations
gh release create <tag> --generate-notes
gh release list
gh release download <tag>
gh release upload <tag> <file>
Workflow Operations
gh workflow list
gh workflow run <name>
gh run list
gh run view <run-id>
gh run watch <run-id>
Gist Operations
gh gist create <file>
gh gist list
gh gist view <id>
Skill Operations
gh skill search <query>
gh skill preview <owner/repo> <skill>
gh skill install <owner/repo> <skill> --dir .agents/skills
gh skill list --dir .agents/skills
gh skill update <skill> --dir .agents/skills --dry-run
gh skill update <skill> --dir .agents/skills --all
gh skill is in preview; check gh skill --help for availability. Run project-scoped commands from Bub's workspace and use --dir .agents/skills; use --dir "$HOME/.agents/skills" for user-scoped skills. Keep gh's source-tracking metadata so installed skills can be updated.
Tips
- Use --web to open in browser
- Use -R owner/repo to specify repository
- Use --json with --jq for scripting
- Use
GH_PROMPT_DISABLED=1and supply required flags for unattended execution. - Write issue, PR, and comment body files as UTF-8 Markdown with real newlines. Pass them with
--body-file, or use--body-file -with a quoted heredoc to preserve shell-sensitive text. - Use an explicit
--headwithgh pr createto avoid implicit pushes or forks; the head branch must already exist remotely.
Files in this skill
1gh skill questions
How do I install the gh skill in Claude Code?
Run npx degit bubbuild/bub/src/skills/gh ~/.claude/skills/gh. Claude Code loads skills from ~/.claude/skills (all projects) or .claude/skills (one project) and uses a skill when its description matches the task.
Which clients can use the gh skill?
Any client that reads the Agent Skills format: Claude Code, Codex, Gemini CLI and claude.ai (upload as a ZIP). Scripts in the skill run only where the client allows code execution.
How do I check my GitHub CLI authentication status?
You can check your current authentication status by running the command gh auth status.
How can I manage agent skills using the GitHub CLI?
You can use the gh skill command to search, preview, install, list, or update agent skills, specifically using the --dir .agents/skills flag for project-scoped commands.
What should I do if I am not authenticated?
If you are not authenticated, you should report the blocker rather than switching credentials silently, and you can run gh auth login if the user requests authentication setup.