TLDR Web Dev · OPINIONS & ADVICE

WORKING WITH STACKED BRANCHES IN GIT IS EASIER WITH --UPDATE-REFS

andrewlock.net8 min read

Summary from the TLDR Web Dev newsletter

Git 2.38 introduced the --update-refs feature to streamline the process of rebasing stacked branches. This new feature automatically updates dependent branches when the base branch is rebased, eliminating the need for manual rebasing and potential conflicts. It can be used in various scenarios, including rebasing a stack of branches, updating stacked branches on a changed branch, and interactive rebasing.