gh-cli
Installation
SKILL.md
GitHub CLI (gh)
Use gh as the first choice for GitHub work that can be done from the command line: repository inspection, issue and pull request management, actions runs, releases, gists, and authenticated GitHub API calls.
For exact flags and current behavior, run gh help, gh <command> --help, or read the official GitHub CLI manual.
Operating principles
- Prefer
ghover ad hoc browser steps for GitHub operations, especially when output must be copied, filtered, or scripted. - Inspect before mutating. Run a read-only command first when context, repository, branch, or account is uncertain.
- Be explicit about repository scope with
--repo OWNER/REPOwhen not operating from the target repository checkout. - Use
--jsonwith--jqfor structured output instead of parsing human-oriented tables. - Avoid interactive prompts in automation. Use flags such as
--body-file,--title,--label,--assignee,--confirm, or--yesonly after checking the command help and confirming the operation is safe. - Treat destructive operations as high risk: delete, close, merge, archive, release deletion, secret updates, workflow cancellation, and permission changes require extra verification.
Initial checks
Before relying on gh, check the basics: