Skip to content
  • Julien "_FrnchFrgg_" Rivaud's avatar
    Make tagification ignore merges by default · 8b986587
    Julien "_FrnchFrgg_" Rivaud authored and Eric S. Raymond's avatar Eric S. Raymond committed
    Initially, reposurgeon tagified commits without fileops before outputting
    the git-fast-import stream because such empty commits are silently
    ignored by git at import time. It did so for both regular commits and
    for merge commits (commits with several parents).
    
    This is not optimal for several reasons:
     - A merge commit without fileops is a merge commit with no file
       contents difference to its first parent. It is completely legitimate
       (this is a merge with "ours" strategy).
     - A merge commit is not ignored by git-fast-import, even if it has no
       fileops.
     - Deleting a merge commit propagates the additional parents to the
       commit children, whose messages won't have information pertaining to
       the merge. These children might even be merges, which now makes them
       octopus merges. All that can be confusing, especially since the
       deletions are automatic and not explicitly asked for.
    
    Make tagify_empty skip merge commits by default, but accept a |tagify_merges|
    parameter to ask for the previous behaviour. Also add a corresponding
    "--tagify-merges" option to the tagify command, and update the tagify
    test so that it exercises the new behaviour.
    8b986587