DEV Community

Discussion on: Git Merge vs Git Rebase

Collapse
 
mugenhere profile image
Mugen

The second image on this page is incorrect (git-merge-2.png). It shows a green dot before master and after merging this with the branch. This is how the image should be after the merge:

If you were in the master branch and then "git merge feature-branch", then you get:

--()--()--|---()--(feature branch HEAD)---|
\ \
-- ()-- (green commit)--------(master HEAD)

Note that master is incremented and it contains the feature branch now. The existing master branch commits are before the merge. In your image they appear after the merge which is wrong.