Information Technology Reference
In-Depth Information
A fast-forward , also denoted by FF, is a process of updating a branch by moving it
forward in the graph. It occurs when the branch you merge into is merged in a branch
that it is already merged in. In that case no new commits are created. The only result of
the command is an updated SHA-1 hash for a branch you merge in (your current
branch). Fast-forward is not possible if your branches have diverged.
In the other case, when FF is not possible, the $ git merge command performs
a merge by creating a new commit. This new commit is quite special: it has at least
two parents. Not surprising, it is called a merge commit .
After this chapter you should be able to merge an arbitrary number of branches and,
if you are not satisfied with the result, undo the operation. You know how to force a
non-fast-forward merge even in cases when the operation would be, by default, carried
out as fast-forward. And finally, you know how to use a --ff-only switch to avoid
performing non-fast-forward merges.
All of these aspects of merging will be important when we dive into workflows.
Search WWH ::




Custom Search