Version Control · Flashcard

What is a key difference between merging and rebasing?

  • AMerge preserves history with a merge commit; rebase rewrites it linearly
  • BMerge rewrites history linearly; rebase adds a commit with two parents
  • CMerge works only on local branches; rebase works only against a remote
  • DMerge requires resolving conflicts; rebase can never produce a conflict

Why this is the answer

Merge keeps a branching history (merge commit); rebase produces linear rewritten history. The reversal is wrong, both are local operations, and rebase can also conflict.

Official docs
Study in Gnoseed →