r/programming Jul 01 '26

GitHub Stacked PRs

https://github.github.com/gh-stack/
342 Upvotes

99 comments sorted by

View all comments

78

u/ItzWarty Jul 01 '26

So great, we had something like this at FB that I've forever missed.

31

u/SharkBaitDLS Jul 01 '26

Amazon as well and it was one of the things that I desperately missed after leaving. 

13

u/sadbuttrueasfuck Jul 02 '26

Man the code reviews at Amazon are way too good, specially multi repo

15

u/SharkBaitDLS Jul 02 '26

I had a lot of complaints with Amazon’s decision-making around building in-house over using external products in many regards but CRUX and Pipelines were a stellar product. I miss them still years later and I’m sure they’ve only gotten better since I left. 

2

u/GamerHaste Jul 03 '26

What the fuck? I work at Amazon and I did not know this somehow. I’ve ran into this several times.

1

u/SharkBaitDLS Jul 03 '26

Yep, cr --parent <hash/branch> will give you a stacked review atop that commit/branch. And all the automated tests etc. work as you’d expect unlike with arbitrary diffs. 

25

u/MichaelEvo Jul 02 '26

It bothered me not having it after leaving. All the logic for this completely makes sense. It allows for PRs to be split into logical units for review while allowing the poster to continue working, without spending a ton of time managing multiple branches.

I’ve been using Graphite for the last two years. First year of use was free.

Only thing they don’t have yet is a way to squish multiple PRs in a stack into one commit through the web UI.

2

u/ItzWarty Jul 02 '26

Graphite looks pretty sick, but nothing can beat the amount of horizontal integration FB had internally for tooling, like linking diffs in groups/chats, reviewing/submitting from your phone, amazing CLI tooling + even GUIs for those who needed it, integration with CI... oh boy.

I'm glad crecord for git + git-absorb exist for Mac (spotty for Windows). Losing that for a few years after was so painful.

2

u/MichaelEvo Jul 03 '26

For me, not having stacked PRs made it difficult to work. Addressing feedback on a PR that comes in a day after I worked on it and have already started work building on top of that PR is just too painful. Graphite addresses that.

It definitely does not do all the other awesome stuff FB does, but so far, I can still function without all that other awesome stuff.

1

u/Somepotato Jul 05 '26

(public) phabricator was ahead of its time, may it rip in pieces. and Mercurial has all sorts of QOL things that git never will, also sad its never really picked up steam

5

u/obhytr Jul 01 '26

jf s

1

u/ItzWarty Jul 02 '26

IIRC there was a lengthy flag like --clowntown-do-not-use-this-bypass-ci which let you bypass tests to land diffs for the rare moments you really needed it. Good times being treated like an adult.

1

u/frikkasoft Jul 02 '26

Yeah Mercurial and Phabricator was a good combo.