Git · Junior · Question 21 of 75

When does Git create a merge commit?

Explanation

With divergent histories Git combines them in a commit with two parents. Conflicts or not, that commit is needed; with a linear history a fast-forward is enough.

Further reading

Problem with a question

Git · Junior · question 21

Test yourself

Take the Git · Junior quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz