Software DevelopmentOfficial · trailofbits

Gh Cli skill for Claude

Enforces authenticated gh CLI workflows over unauthenticated curl, WebFetch, and MCP fetch patterns.

When Claude uses it

Use when working with GitHub URLs, API access, pull requests, or issues.

Gh Cli SKILL.md

The full skill file from trailofbits/skills (CC-BY-SA-4.0).

gh-cli

When to Use

  • Working with GitHub repositories, pull requests, issues, releases, or raw file URLs.
  • You need authenticated access to private repositories or higher API rate limits.
  • You are about to use curl, wget, WebFetch, or an MCP fetch tool against GitHub.

When NOT to Use

  • The target is not GitHub.
  • Plain local git operations already solve the task.

Guidance

Prefer the authenticated gh CLI over raw HTTP fetches for GitHub content. In particular:

  • Prefer gh repo view, gh pr view, gh pr list, gh issue view, and gh api over unauthenticated curl or wget.
  • Prefer cloning a repository and reading files locally over fetching raw.githubusercontent.com blobs directly.
  • Avoid using GitHub API /contents/ endpoints as a substitute for cloning and reading repository files.

Examples:

gh repo view owner/repo
gh pr view 123 --repo owner/repo
gh api repos/owner/repo/pulls

For the hook implementation, see:

  • plugins/gh-cli/README.md
  • plugins/gh-cli/hooks/

How to install Gh Cli

Claude Code

Copy the skill into your personal skills folder (or into .claude/skills/ inside a project):

npx degit trailofbits/skills/plugins/gh-cli/skills/gh-cli#main ~/.claude/skills/gh-cli

Codex

npx degit trailofbits/skills/plugins/gh-cli/skills/gh-cli#main ~/.codex/skills/gh-cli

Claude.ai and Claude Desktop

Download the skill folder from GitHub, zip it, and upload it under Settings → Capabilities → Skills.

Frequently asked questions

+What does the Gh Cli skill do?

Enforces authenticated gh CLI workflows over unauthenticated curl, WebFetch, and MCP fetch patterns. Use when working with GitHub URLs, API access, pull requests, or issues.

+How do I install Gh Cli in Claude Code?

Copy the skill folder into ~/.claude/skills/gh-cli, for example with "npx degit trailofbits/skills/plugins/gh-cli/skills/gh-cli#main ~/.claude/skills/gh-cli". Claude Code loads it automatically and uses it when a task matches.

+Does Gh Cli work with ChatGPT or Codex?

Yes. Gh Cli uses the open SKILL.md format. In Codex, put the folder in ~/.codex/skills/gh-cli. In Claude.ai, zip the folder and upload it under Settings → Capabilities → Skills.

+Is Gh Cli free?

Gh Cli is published on GitHub by trailofbits under the CC-BY-SA-4.0 license, which allows free use.

Related software development skills

  1. Code Review

    Review the changes since a fixed point (commit, branch, tag, or merge-base) along two axes: Standards (does the code follow this repo's…

    mattpocock/skills★ 327k
  2. Using Agent Skills

    Discovers and invokes agent skills. Use when starting a session, or when you need to decide which skill or workflow applies to the piece of…

    addyosmani/agent-skills★ 119k
  3. Build

    Fully automate a coding task with make-plan, do, and babysit.

    thedotmack/claude-mem★ 118k
  4. Github Triage

    Official

    Triages a repository's open GitHub issues and pull requests via the gh CLI.

    trailofbits/skills★ 8.3k
  5. Graph Evolution

    Official

    Compares Trailmark code graphs at two source code snapshots (git commits, tags, or directories) to surface security-relevant structural…

    trailofbits/skills★ 8.3k
  6. Hunt Regressions

    Official

    Use when discovering possible regressions from a pinned change and its callers before reproduction.

    trailofbits/skills★ 8.3k
  7. Implement Patch

    Official

    Use when a confirmed local bug needs an invariant-level fix, variant search, tests, and one local commit.

    trailofbits/skills★ 8.3k
  8. Modern Cpp

    Official

    Guides C++ code toward modern idioms (C++20/23/26). Use when writing new C++ code, modernizing legacy patterns, or working on…

    trailofbits/skills★ 8.3k
  9. Modern Python

    Official

    Configures Python projects with modern tooling (uv, ruff, ty).

    trailofbits/skills★ 8.3k

See all software development skills →

More skills from trailofbits

  1. Goal Prompt

    Official

    Drafts copy-paste-ready /goal commands for goal mode in Claude Code and Codex.

    trailofbits/skills★ 8.3k

All skills by trailofbits →

Give your whole team an AI agent with skills

Cody runs managed AI agents your team can message in Slack, Teams, WhatsApp and the web, with 50+ business integrations, scheduled tasks and memory. No terminal required.