mrkeyoor.com_
Sun 01 Nov 03:58 UTC
Dev Toolsevaluationupdated 24 Oct 2026

gh-stack review

GitHub Stacked PRs (gh-stack) is a GitHub CLI extension for managing dependent branches and pull requests. Its README describes creating branches, rebasing layers, assigning PR bases, navigating stacks, and submitting or merging them through `gh stack`.

+11stars / 7d
Verdict

gh-stack is worth evaluating for teams that already use GitHub CLI and understand dependent branches. Its documented workflow covers stack creation, rebasing, submission, and recovery, but our October 10, 2026 run at 29a36d3 does not verify extension installation or a working GitHub workflow: the setup and build-labelled steps exited 0, while go test exited 1. That failure does not establish that the product is broken. Before adopting it, check your installed version, exercise a disposable stack, and verify remote branch tips and PR state after synchronization. Current documentation supports shared worktree metadata, so the earlier worktree-local storage report should not remain a blanket reason to avoid it.

We ran it

Lab card: what happened when we ran gh-stackScreenshot of gh-stack (gh.io/stacks)
Install✓ · 38s204 packages
Build✓ · 36s
Tests✗ · 379s30 passed · 5 failed of 35 (go test)
Repo201 files~68,885 lines of source · 6.5 MB · 3 CI workflows

Answers from our run

Does gh-stack build from source?

Dependencies installed in 38 seconds (204 packages), and the build succeeded in 36 seconds. We cloned commit 29a36d3 into a clean Debian container with 3 CPUs and no project-specific setup.

Do gh-stack's tests pass?

No. The project's own test command finished in 379 seconds and reported 30 passed, 5 failed (go test).

Who should not use gh-stack?

Teams that require an exit code alone to prove remote synchronization completed. Issue 472 reports misleading success after a push failure, including a confirmation on v0.2.0 dated October 6, 2026.

What are the alternatives to gh-stack?

Git Town, git-spice. gh-stack is worth evaluating for teams that already use GitHub CLI and understand dependent branches.

Setup3/5The README provides one extension-install command and explicit GitHub CLI and Git requirements. Our 38-second setup step shows a toolchain download, not verified extension installation.
Docs4/5The supplied README details command behavior, shared worktree state, recovery, partial pushes, and merge-queue limits. Documentation is more complete than our execution evidence.
Community2/5Supplied issues show user follow-up in October 2026, including a worktree-resolution acknowledgment. They do not establish adoption scale, response-time consistency, or support capacity.
Maturity2/5Release notes and recovery documentation provide useful evidence, but issue 472 has a v0.2.0 confirmation and our test step exited 1. Failure causes and the installed release's behavior remain unverified.

Discussed on

  1. hnGitHub Stacked PRs900 points

Who it’s for

GitHub teams that want a large change reviewed as smaller, dependent pull requests.
Developers who understand rebasing and can coordinate history changes with collaborators.
GitHub CLI users willing to validate remote results before adding stack commands to automation.

Who it’s NOT for

Teams that require an exit code alone to prove remote synchronization completed. Issue 472 reports misleading success after a push failure, including a confirmation on v0.2.0 dated October 6, 2026.
Repositories whose workflow cannot accommodate rebasing and force-with-lease pushes.
Readers seeking a verified installation or authenticated GitHub workflow benchmark: our recorded run establishes neither.

Setup reality

In our recorded run on October 10, 2026, at commit 29a36d314be664583705f18e41cebdf2b61ad514, the install-labelled step exited 0 in 38 seconds. Its retained output shows a Go 1.26.0 toolchain download; it does not establish that the GitHub CLI extension was installed. The dependency metric recorded 204. The build-labelled step exited 0 in 36 seconds, with retained output vet-exit:0, which does not independently demonstrate a compiled or installed binary.

The go test step exited 1 after 379 seconds. The parser recorded 30 package successes and 5 package failures, with a separate no-tests package entry. These are recorded parser summaries, not verified counts of unique individual tests or exhaustive package coverage. The retained log includes failures for cmd and internal/modify; it does not establish the cause of every failure.

The recorded environment had 3 CPUs, 8 GB of memory, and image golang:1.24-bookworm. The image name does not establish the runtime version; the retained output identifies a downloaded Go 1.26.0 toolchain. The checkout scan recorded 201 files, approximately 68,885 source lines, 6.5 MB, and 3 CI workflows, with no Dockerfile or tests directory detected. No authenticated push, PR submission, merge, installed-binary check, or workload benchmark is documented.

The README requires GitHub CLI v2.0+ and Git 2.36+ and documents gh extension install github/gh-stack. That documented installation path is separate from our recorded setup step.

GitHub Stacked PRs can help a GitHub team review dependent changes in smaller pieces. The adoption question is whether its documented branch workflow fits your team and whether you have verified the remote operations you plan to automate.

What the extension manages

The README describes an ordered chain of branches above a trunk branch. On submission, each branch becomes a pull request whose base is the branch below it, giving reviewers the diff for that layer. Navigation moves through the chain; rebase updates dependent history; modify previews changes such as inserting, folding, renaming, or reordering layers.

The documented quick start uses gh stack init, adds another layer, pushes branches, views the stack, and submits PRs. Initialization also enables Git rerere to remember conflict resolutions. These are documented capabilities, not operations demonstrated by our sandbox run.

What our recorded run establishes

Our run was recorded on October 10, 2026, at commit 29a36d314be664583705f18e41cebdf2b61ad514. The environment record lists 3 CPUs, 8 GB of memory, and image golang:1.24-bookworm.

The install-labelled step exited 0 after 38 seconds. Its retained output is a Go 1.26.0 toolchain download, and the dependency metric records 204. This does not prove that gh extension install ran or that an extension binary was installed. The build-labelled step exited 0 after 36 seconds, but its retained output is vet-exit:0; compilation and binary execution are not independently established by that tail.

The go test step exited 1 after 379 seconds. The stored parser summary records 30 package successes and 5 package failures, plus a separate no-tests package entry. The summary has not been reconciled against complete logs for unique, exhaustive coverage. It must not be presented as 30 individual tests passing out of 35.

The retained output names failures in github.com/github/gh-stack/cmd and github.com/github/gh-stack/internal/modify, with durations around 360 seconds. The harness records that the overall step was not timed out. The available tail does not explain every failure or establish whether the cause was a product defect, test behavior, or the environment.

The checkout scan recorded 201 files, approximately 68,885 source lines, 6.5 MB, and 3 CI workflows. It detected no Dockerfile or tests directory. That directory result says nothing about the absence of Go tests, which the command did execute. No authenticated GitHub operation, installed-binary check, or measured user workload is documented.

Check remote results before trusting automation

Issue 472 reports that gh stack sync printed success and exited 0 after its internal push failed on v0.1.0. A commenter confirmed the behavior on v0.2.0 on October 6, 2026. This is an attributed issue report, not a failure reproduced in our run or proof that every later build behaves the same way.

The current README also documents a separate case: in a non-interactive terminal, genuinely divergent local and remote stacks cause sync to stop with exit success without pushing or updating PRs. Scripts therefore need to verify the intended remote result rather than equating exit 0 with changed remote state.

Push and merge have different guarantees. The README says push uses explicit per-branch force-with-lease checks and is not atomic: some branches may update while another is rejected. It describes direct stacked merges as all-or-nothing, while merge queues may process the selected PRs in separate groups. Repository rules still apply.

Issue 467 records a one-PR stack whose submit command reported success while merge said the stack had not been submitted, on v0.1.0 and commit ab00aa4. Treat that as a version-specific report. The supplied evidence does not establish its behavior in the version you will install.

Worktree documentation has moved beyond the original report

Issue 459 originally described worktree-local metadata that could disappear when a linked worktree was removed. The current README instead documents a shared catalog at <common-dir>/gh-stack, normally .git/gh-stack, along with shared recovery journals. The issue author wrote on October 23, 2026 that the problem looked resolved. That supports removing the old blanket worktree warning, without claiming our run verified the fix.

The README says rebase and sync update clean worktrees that own affected branches and stop when owners are dirty, busy, missing, or changed. Its locks coordinate gh-stack processes, not arbitrary Git commands or editors. Keep affected worktrees idle during history rewrites, and follow the documented continue or abort path for paused operations. Do not mix old and new gh-stack versions within one clone.

Installation and a useful next step

The README requires GitHub CLI v2.0+ and Git 2.36+ and documents gh extension install github/gh-stack. A successful dependency download in our sandbox is separate from completing that installation.

For an evaluation, confirm the installed extension version, use a disposable repository with the permissions your real workflow needs, and check remote branch tips and PR bases after submit and sync. Include conflict recovery and your repository's merge policies before relying on unattended operation. These are recommended checks, not tests we performed.

The supplied v0.1.0 release notes document the addition of stacked merging and fixes for stale-trunk handling and amended-parent history. They do not establish v0.1.0 as the latest release; issue 472 includes a later v0.2.0 report.

Alternatives and rating scope

Git Town documents branch creation, synchronization, shipping, cleanup, and stacked changes across several Git workflow styles. It fits readers looking for a broader branch workflow tool. git-spice documents stacked branches and pull or merge requests on GitHub, GitLab, Bitbucket, Gitea, and Forgejo. It fits readers who need those hosting options. Neither alternative was tested in our run.

Scores use a five-point editorial rubric: 1 means little usable support or a substantial documented obstacle; 2 means limited evidence with important unresolved checks; 3 means a documented path with material qualifications; 4 means detailed support with narrower gaps; 5 requires strong corroboration within the stated scope. These scores assess the evidence available for each category, not overall reliability. Unknown adoption is not evidence of a strong community, and a failed test command alone is not a maturity verdict.

Alternatives

ProjectWhat it isPick it when
Git TownAdditional Git commands for creating, synchronizing, shipping, and cleaning up branches, including stacked changes.Choose it when you want branch workflow commands covering both stacked changes and workflows such as Git Flow or trunk-based development.
git-spiceA tool for managing stacked Git branches and submitting pull or merge requests to several hosting services.Choose it when your stacked-branch workflow needs GitHub, GitLab, Bitbucket, Gitea, or Forgejo support.

What people are saying

  1. [github-trending] github/gh-stack

Sources

  1. GitHub Stacked PRs README
  2. gh-stack v0.1.0 release
  3. Issue 472: sync exits successfully after push failure
  4. Issue 459: stack metadata across worktrees
  5. Issue 467: one-PR stack submit and merge conflict

More dev tools reviews

cloc · rufus · linux-insides · cat-catch · date-fns · okhttp · the whole board →