WTF is Git Rebase

Git's 3 merge types

Created by Thanh Ha / @zxiiro

Agenda

  • What is a Merge?
  • What is a Merge Commit?
  • What is a Rebase?

Merge

AKA Fast Forward Merge (--ff-only)


$ git merge [--ff-only] new_feature
                        

Result of a FF Merge

Merge Commit

AKA Non-Fast Forward Merge (--no-ff)


    $ git merge [--no-ff] new_feature
                        

Result of Merge Commit


    $ git merge [--no-ff] new_feature
                        

Forced Merge Commit

AKA Non-Fast Forward Merge (--no-ff)


    $ git merge --no-ff new_feature
                        

Result of a Forced Merge Commit


    $ git merge --no-ff new_feature
                        

Rebase

AKA Rewriting history


    $ git rebase origin/master
                        

Result of Rebase


    $ git rebase origin/master
                        

Questions?