Rebasing Multiple Branches
Task
Arrange the changes of three side branches into one linear chain on top of main. At the start, HEAD is on bugFix.
Steps
- Rebase
bugFixontomain. - Switch to
sideand rebase it onto the updatedbugFix. - Switch to
anotherand rebase it onto the updatedside.
Expected result
The history must become linear in the order main → bugFix → side → another. HEAD must end up on another.
What you will learn
After completing the task, you will be able to:
- rebase several branches one after another;
- choose a new base for each next branch;
- plan the order of rewriting dependent lines of history.
Goal
local