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

[RFC/PATCH 2/2] builtin-merge: show user-friendly error messages for fast-forward too.

From
Matthieu Moy <matthieu.moy@imag.fr>
Date
Nov 29, 2009, 12:18 UTC
Message-ID
<1259497113-1393-3-git-send-email-Matthieu.Moy@imag.fr>
In-Reply-To
<1259497113-1393-1-git-send-email-Matthieu.Moy@imag.fr>

fadd069d03 (merge-recursive: give less scary messages when merge did not start, Sep 7 2009) introduced some friendlier error message for merge failure, but the messages were shown only for non-fast forward merges. This patch uses the same for fast-forward.

Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>
---
This is where I'm not 100% sure I'm not breaking some plumbing.
 builtin-merge.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/builtin-merge.c b/builtin-merge.c
index 57eedd4..0dd363f 100644
--- a/builtin-merge.c
+++ b/builtin-merge.c
@@ -656,6 +656,7 @@ static int checkout_fast_forward(unsigned char *head, unsigned char *remote)
 	opts.verbose_update = 1;
 	opts.merge = 1;
 	opts.fn = twoway_merge;
+	opts.msgs = get_porcelain_error_msgs();
 
 	trees[nr_trees] = parse_tree_indirect(head);
 	if (!trees[nr_trees++])
-- 
1.6.5.3.435.g5f2e3.dirty
Previous: Matthieu MoyNext: Junio C Hamano
Message 3 of 5 in “User-friendly error messages for merge failure on fast-forward.”
  1. 0/2 User-friendly error messages for merge failure on fast-forward.Matthieu Moy, Nov 29, 2009
  2. 1/2 merge-recursive: make the error-message generation an extern functionMatthieu Moy, Nov 29, 2009
  3. 2/2 builtin-merge: show user-friendly error messages for fast-forward too.Matthieu Moy, Nov 29, 2009
  4. Junio C HamanoNov 30, 2009
  5. Matthieu MoyNov 30, 2009

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.