![]() When you merge checkout into main, you’ll automatically re-target the second pull request to now merge into main. One branch merges into the branch below it in the stack, and as a result, GitHub will only show the diff between those two changes, allowing your reviewer to understand the stack in bite-sized pieces. One merging branch promo_codes into checkout.To create that stack, you can create two pull requests on GitHub: Let’s say you have a stack going: main → checkout → promo_codes. GitHub thankfully has basic inbuilt support for stacks. Good question! And no, this will not confuse your teammates. Now, I’m sure you’re asking, will this confuse my teammates? How to incorporate stacking into a team environment Pull Request #7: Add a real dictionary with wordsĪs a reviewer, which of those two was easier to read? Which one are you likely to review faster? Which one do you think will get merged first? Let us know what you think in the comments section.Pull Request #6: Add a win condition and a reset button.Pull Request #5: Show which letters are correct.Pull Request #3: Keep track of past guesses.Here is a PR building all of Wordle all at once.Īnd here is a stack of eight that does the same thing: Over at Graphite, we recently wrote about how to build Wordle using stacking. No need to wait for that feature to land, just branch and go. Branching off of a feature branch allows you pick up your work where you left off. Why would I branch off of a feature branch? Hold on, you’re saying - we always branch off of main. The principle is simple: once you’ve finished writing a feature, you commit it to your feature branch, move it up the branch for review, and create a branch off of that feature branch. Stacking is the best-kept secret of high-performing developers. How to incorporate stacking into a team environment?.Fold it into the first PR: There’s nothing a developer likes to receive more than multi-thousand line code review.Bother your reviewer: Also not awesome, you’re just going to slow them down.Work on something else: This isn’t awesome, you have the entire codebase for comments in your head right now, and moving to something else is just going to slow you down. ![]() Promo codes are built on top of the checkout flow, but you realize you can’t build on top of the checkout flow because your first pull request hasn’t landed yet - it’s stuck in code review. You just finished writing the new checkout flow for your shopping app, and now you need to add a promo codes feature. Stay unblocked in code review and build products faster with stacking Hobbyist photographer, runner, and writer. Tomas Reimers Follow Co-founder of Graphite previously Facebook NY and Harvard. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |