github-stacked-pr

Chain dependent Git branches and automate stacked PR submission via gh-stack.

Updated Oct 15, 2021
One-click install
npx skills add https://github.com/toqoz/config --skill github-stacked-pr
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: github-stacked-pr
Source: https://github.com/toqoz/config/tree/main/home/agents/skills/github-stacked-pr
Command: npx skills add https://github.com/toqoz/config --skill github-stacked-pr

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires gh, gh-stack, git.

What problem does it solve?

This skill solves the complexity of managing large, monolithic pull requests by enabling the creation of a chain of smaller, independently reviewable pull requests that target each other.

Core Features & Use Cases

  • Automated Stack Management: Uses gh-stack to handle branch creation, dependency tracking, and PR submission.
  • Logical Layering: Facilitates splitting complex features into manageable chunks like refactors, schema changes, and implementation.
  • Use Case: When working on a large feature, use this skill to break the work into a base migration PR, an API implementation PR, and a UI integration PR, ensuring each is reviewed and merged in order.

Quick Start

Use the github-stacked-pr skill to split my current branch into a stack of three pull requests based on the main branch.

Frequently Asked Questions about github-stacked-pr

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

FAQPage Schema
How do I split a large pull request into smaller, independently reviewable GitHub PRs?

Stacked pull requests split large features into a chain of smaller, independently reviewable PRs that target each other. This skill uses gh-stack to organize branches sequentially, ensuring each part is reviewed and merged in logical order.

What is the best way to manage stacked pull requests for complex Git branches?

Managing stacked pull requests involves chaining dependent Git branches and automating PR submission via the gh-stack extension. This approach organizes large feature sets into sequential layers like schema changes, API implementation, and UI integration.

Do I need the GitHub CLI and gh-stack to automate stacked PR creation?

Yes, automating stacked PR creation requires the GitHub CLI and the gh-stack extension to be installed and authenticated within your local development environment to handle branch creation, dependency tracking, and PR submission.

Can I break a monolithic feature branch into multiple layers like refactors and implementation PRs?

Yes, you can break a monolithic feature branch into multiple layers like refactors, schema changes, and implementation. This skill facilitates logical layering so each chunk is managed as an independent, sequentially merged pull request.

Why use stacked pull requests instead of a single large pull request for code review?

Stacked pull requests solve the complexity of managing monolithic PRs by creating a chain of smaller, manageable chunks. This modular code review workflow ensures large feature sets are reviewed sequentially and merged in dependency order.

How do I submit a stack of three pull requests based on the main branch?

To submit a stack of three pull requests, use this skill to split your current branch into sequential layers based on the main branch. The gh-stack extension automates the branch chaining and PR submission across the stack.