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

[PATCH 4/4] git.el: Include MERGE_MSG in the log-edit buffer even when not committing a merge.

From
AJAlexandre Julliard <julliard@winehq.org>
Date
Nov 3, 2006, 16:42 UTC
Message-ID
<87zmb81ny4.fsf@wine.dyndns.org>

This lets us take advantage of the fact that git-cherry-pick now saves the message in MERGE_MSG too.

Signed-off-by: Alexandre Julliard <julliard@winehq.org>
---
 contrib/emacs/git.el |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/contrib/emacs/git.el b/contrib/emacs/git.el
index 6f3b46d..972c402 100644
--- a/contrib/emacs/git.el
+++ b/contrib/emacs/git.el
@@ -589,6 +589,7 @@ and returns the process output as a stri
                           (let ((commit (git-commit-tree buffer tree head)))
                             (git-update-ref "HEAD" commit head)
                             (condition-case nil (delete-file ".git/MERGE_HEAD") (error nil))
+                            (condition-case nil (delete-file ".git/MERGE_MSG") (error nil))
                             (with-current-buffer buffer (erase-buffer))
                             (git-set-files-state files 'uptodate)
                             (when (file-directory-p ".git/rr-cache")
@@ -888,7 +889,7 @@ and returns the process output as a stri
           'face 'git-header-face)
          (propertize git-log-msg-separator 'face 'git-separator-face)
          "\n")
-        (cond ((and merge-heads (file-readable-p ".git/MERGE_MSG"))
+        (cond ((file-readable-p ".git/MERGE_MSG")
                (insert-file-contents ".git/MERGE_MSG"))
               (sign-off
                (insert (format "\n\nSigned-off-by: %s <%s>\n"
-- 
1.4.3.3.gf3240

-- 
Alexandre Julliard
Message 1 of 1 in “git.el: Include MERGE_MSG in the log-edit buffer even when not committing a merge.”
  1. 4/4 git.el: Include MERGE_MSG in the log-edit buffer even when not committing a merge.Alexandre Julliard, Nov 3, 2006

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.