Agent skill · software engineering · remotion-dev
gh-stack
Manages stacked PRs and splits multi-part work into reviewable branches with gh-stack. Use for stack creation, viewing, edits, push, submit, sync, rebase, merge, or checkout; when asked to split or isolate work for review; whenever a user mentions a stack, branch layers, dependent PRs, or gh stack; or when a stack is checked out.
Why this skill is useful
Adds specific commands and workflows for managing stacked PRs that the AI wouldn't reliably generate on its own.
What it needs
Requires gh installed locally. About 6k tokens when loaded. Last updated 2026-08-06. 55,698 stars on the source repository.
What this skill does
gh-stack gh stack is a GitHub CLI extension for stacked branches and pull requests. A stack is an ordered chain of branches rooted on a trunk, where each branch has one PR based on the branch below it, so a reviewer sees only that layer's diff. gh stack prints a stack trunk-first, left to right: Left is the bottom, right is the top. auth is based on main and merges first; frontend merges last. up moves toward the top, away from trunk; down moves toward it. Foundational work belongs at the bottom, code that depends on it above. For how to choose the layers, read references/stack-design.md. Setup Non-interactive use gh stack branches on whether stdout is a TTY. Piped, most commands error cleanly or print static text; under a PTY the same commands open a prompt or a full-screen TUI and block forever. Agent harnesses differ, so always pass the flags below instead of relying on that detection. Multiple remotes: never run push, submit, sync, rebase, or link without --remote <name> unless remote.pushDefault is configured. checkout and trunk have no --remote flag and require the config. Always run Never run bare Why ----------------------------------------- ------------------- --------------------------------------------- gh stack view --json gh stack view opens a TUI under a PTY gh stack submit --auto gh stack submit prompts for a title per new PR gh stack merge <target> --yes --squash gh pr merge gh pr merge cannot merge a stack gh stack init <branch>... gh stack init prompts for branch names gh stack add <branch> gh stack add prompts for a name, and fails even when piped gh stack checkout <target> gh stack checkout opens a selection menu gh stack up / down / top / bottom gh stack switch switch is menu-only — gh stack modify TUI-only, no non-interactive path view --short is safe in both modes, but it is formatted for humans. Use --json to parse. checkout <pr> when a different local stack already covers those branches cannot be forced. …
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills remotion-dev/gh-stack