Skip to content

Turning Conflicts: hint into comment

Junio C Hamano git 2 versions New

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest4 patches 0 repliesNew
  2. v11 patch 1 replySuperseded

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4builtin/merge.c: drop a parameter that is never usedbuiltin/merge.c+2 -20 replies
2/4merge & sequencer: unify codepaths that write "Conflicts:" hintbuiltin/merge.c sequencer.c sequencer.h+26 -280 replies
3/4builtin/commit.c: extract ignore_non_trailer() helper functionbuiltin/commit.c+33 -260 replies
4/4merge & sequencer: turn "Conflicts:" hint into a commentbuiltin/commit.c sequencer.c t/t3507-cherry-pick-conflict.sh+68 -280 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH v2 0/4] Turning Conflicts: hint into comment

So here is a reroll to hopefully bring this topic closer to perfection.

The first two patches haven't changed, except that they are now part of a numbered series.

The third patch is a refactoring that helps clarify what happens in the last step, which is new.

The endgame is similar to what was posted before, except that we pay attention to "Conflicts:" and HT indented pathnames in addition to comments and blanks when determining the true end of the log message. This is so that running "git commit --amend -s" on a commit that was created with older versions of Git by a careless user who left the old conflicts hint around will insert the new sign-off at the right place.

The series is designed to apply on v1.8.5.x series, even though I do not anticpiate that we would need to backport this to maintenance branches. !prefixcmp() will need to turn into starts_with() when merging to newer codebase, which I can let rerere take care of.

Junio C Hamano (4):
builtin/merge.c: drop a parameter that is never used merge & sequencer: unify codepaths that write "Conflicts:" hint builtin/commit.c: extract ignore_non_trailer() helper function merge & sequencer: turn "Conflicts:" hint into a comment

 builtin/commit.c                | 74 ++++++++++++++++++++++++++---------------
 builtin/merge.c                 | 22 ++++--------
 sequencer.c                     | 34 ++++++++++---------
 sequencer.h                     |  1 +
 t/t3507-cherry-pick-conflict.sh | 42 ++++++++++++++++++-----
 5 files changed, 109 insertions(+), 64 deletions(-)
Signature · 1 line
2.1.2-620-g33c52cb