One-click install
npx skills add https://github.com/msbaek/dotfiles --skill gh-msbaek
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: gh
Source: https://github.com/msbaek/dotfiles/tree/main/.claude/skills/gh
Command: npx skills add https://github.com/msbaek/dotfiles --skill gh-msbaek

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides a structured mental model and practical command references for GitHub CLI (gh). It helps developers, operators, and CI engineers work with PRs, issues, releases, and GitHub automation without leaving the terminal, reducing context switching and speed up workflows.

Core Features & Use Cases

  • Mental Model & Command Structure: Understand gh's three-layer approach (porcelain commands, API access, Git integration) and how they map to real-world workflows.
  • Unified Workflow Guidance: Guidance for PR operations (gh pr), issues (gh issue), repository tasks (gh repo), and releases.
  • Automation & API Access: How to use gh api for REST/GraphQL calls and how to integrate with erk for worktree patterns.
  • Reference-Loaded Loading Strategy: When to load the comprehensive references/gh.md and references/graphql.md for advanced graph queries and integration.
  • Use case examples: a daily PR triage, authenticating and configuring gh, and automating 1-click PR creation.

Quick Start

Install and configure GitHub CLI, authenticate, set defaults, and try a simple PR operation like listing open PRs in your current repo.

Frequently Asked Questions about gh

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate GitHub pull request workflows from the command line?

GitHub CLI (`gh`) automates PR operations directly from your terminal using commands like `gh pr create`, `gh pr list`, and `gh pr merge`. It eliminates context switching by letting you manage pull requests, issues, and releases without leaving the CLI, speeding up triage and deployment workflows.

Can I use GitHub CLI to query the GitHub API with GraphQL?

Yes. `gh api` supports both REST and GraphQL queries. You can execute complex GraphQL operations directly from the command line, enabling advanced automation scenarios like custom issue filtering and repository analysis without building separate API clients.

What's the best way to set up GitHub CLI for CI automation and release workflows?

Install `gh`, authenticate with `gh auth login`, configure defaults for your repository, then integrate `gh` commands into CI pipelines or Git worktree patterns. The mental model of gh's three layers—porcelain commands, API access, and Git integration—guides you toward the right tool for each automation task.

Do I need to write custom scripts to integrate GitHub CLI with existing Git workflows?

No. `gh` integrates natively with Git workflows and supports patterns like worktree integration via `erk`. You can chain `gh` commands with shell scripts for one-click PR creation, automated issue triage, and repository operations without custom SDK development.

How do I handle authentication and configure GitHub CLI for multiple repositories?

GitHub CLI provides built-in authentication via `gh auth login` and lets you set host-specific defaults. Once configured, `gh` automatically handles credentials across repositories, simplifying workflows for developers and operators managing multiple projects.