github

Automate GitHub PR operations with gh CLI and GitHub API.

8|2|Updated Nov 2, 2025
One-click install
npx skills add https://github.com/fx/cc --skill github-fx
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: github
Source: https://github.com/fx/cc/tree/main/plugins/fx-dev/skills/github
Command: npx skills add https://github.com/fx/cc --skill github-fx

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

MUST BE USED when working with GitHub: updating PRs, editing PR descriptions/titles, creating PRs, merging, review threads, gh CLI commands, GitHub API, or any pull request operations. This skill loads automatically when using gh commands and improves reliability by providing self-improvement patterns.

Core Features & Use Cases

  • Provides patterns for common gh CLI operations and GraphQL queries.
  • Reduces errors in PR management, reviews, and automation scripts.
  • Self-improvement by documenting solutions to new gh CLI issues.

Quick Start

Load this skill before running gh commands to guide operations like updating a PR title or editing a description.

Frequently Asked Questions about github

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

FAQPage Schema
How do I automate GitHub PR operations with the gh CLI?

Automate GitHub PR operations using gh CLI commands paired with GraphQL queries to create, edit, merge, and manage pull requests reliably. This Skill provides tested patterns for PR creation, title/description updates, merging workflows, and review thread management across diverse repositories, reducing errors in common gh operations.

Can I use gh CLI to update PR titles and descriptions programmatically?

Yes. The gh CLI supports programmatic PR updates through commands and GraphQL patterns. This Skill documents variable-based GraphQL queries and input verification techniques for safely editing PR metadata, handling edge cases, and maintaining compatibility across gh versions.

What are common errors when managing GitHub PRs via CLI and API?

PR management errors include malformed GraphQL queries, version incompatibilities in gh CLI, missing input validation, and pagination failures in batch operations. This Skill addresses these constraints through error-handling patterns, version checks, and documented known-issues guidance to prevent PR mismanagement.

How do I batch process GitHub PR operations with pagination?

Batch process PRs using GraphQL pagination patterns with the gh CLI to handle large result sets efficiently. This Skill provides tested batch workflows and pagination logic for applying operations across multiple PRs while respecting API limits and maintaining reliability.

Does gh CLI support draft PR workflows and review thread management?

Yes. The gh CLI supports draft PR creation and review thread operations through documented commands and GraphQL queries. This Skill includes patterns for draft workflows, thread management, and best practices to ensure reliable review processes across GitHub repositories.

What's the best way to handle GitHub API errors in PR automation scripts?

Handle GitHub API errors in automation by implementing input verification, gh version compatibility checks, and error-recovery patterns. This Skill documents known issues, error handling approaches, and best practices to make PR automation scripts robust across different environments.