Information Technology Reference
In-Depth Information
setting will also serve as a starting point to the discussion of ranges of commits. Before
proceeding with the $ git rebase --onto operation we will cover both the two
dots and three dots operators.
The final recipes in this chapter will deal with bulbs. We learned how to create them
in Recipe 6-6. Rebasing is much more difficult if you want to preserve the merges.
7-1. Rebasing divergent branches
Problem
You work in a repository with two branches named master and feature . The
branches diverged and your repository now looks like Figure 7-1(a) . You want to trans-
form the feature branch in such a way that:
• The history is linear (that means that the branches are not divergent any-
more).
• The master branch is merged into the feature branch.
• All of the commits that were made in the feature branch are at the very
top of the master branch.
The repository you want to achieve is presented in Figure 7-1(b) .
 
 
Search WWH ::




Custom Search