git/list[1] front-page[2] threads[3] people[4] search[5] about
 

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

From
Junio C Hamano <gitster@pobox.com>
Date
Oct 28, 2014, 21:36 UTC
Message-ID
<1414532212-9016-1-git-send-email-gitster@pobox.com>
In-Reply-To
<xmqq1tpxgw6t.fsf@gitster.dls.corp.google.com>

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(-)
-- 
2.1.2-620-g33c52cb
Next: Junio C Hamano
Message 1 of 5 in “Turning Conflicts: hint into comment”
  1. 0/4 Turning Conflicts: hint into commentJunio C Hamano, Oct 28, 2014
  2. 1/4 builtin/merge.c: drop a parameter that is never usedJunio C Hamano, Oct 28, 2014
  3. 2/4 merge & sequencer: unify codepaths that write "Conflicts:" hintJunio C Hamano, Oct 28, 2014
  4. 3/4 builtin/commit.c: extract ignore_non_trailer() helper functionJunio C Hamano, Oct 28, 2014
  5. 4/4 merge & sequencer: turn "Conflicts:" hint into a commentJunio C Hamano, Oct 28, 2014

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.