Has the man page states about git rebase --preserve
:
Merge conflict resolutions or manual amendments to merge commits are not preserved.
Is there any good reason for that?
It would be the same reason for the existence of the command git rerere
(Reuse recorded resolution of conflicted merges)
See "rerere your boat" and "Fix conflicts only once with git rerere".
Git does not record merge conflict resolution for any merge (including the one done again during a rebase -p
)
Basically, a conflict merge resolution is a manual step (meaning a human decision has to be made), which git is not able to reproduce automatically (it is, or rather was, a "stupid" content tracker after all).
Git is only able to record said resolution (if one activates rerere
first)
来源:https://stackoverflow.com/questions/35714919/why-git-rebase-p-does-not-preserve-conflict-resolutions