GNU bug report logs - #64055
31.0.50; log-view-modify-change-comment support for Git and Hg

Previous Next

Package: emacs;

Reported by: Morgan Smith <Morgan.J.Smith <at> outlook.com>

Date: Tue, 13 Jun 2023 23:05:02 UTC

Severity: normal

Tags: patch

Found in version 27.0.50

Full log


View this message in rfc822 format

From: Eli Zaretskii <eliz <at> gnu.org>
To: Sean Whitton <spwhitton <at> spwhitton.name>
Cc: Morgan.J.Smith <at> outlook.com, 64055 <at> debbugs.gnu.org, dgutov <at> yandex.ru
Subject: bug#64055: Implementation of modifying VC change comments for Git
Date: Tue, 22 Oct 2024 17:20:43 +0300
> From: Sean Whitton <spwhitton <at> spwhitton.name>
> Cc: 64055 <at> debbugs.gnu.org,  dgutov <at> yandex.ru,  Morgan.J.Smith <at> outlook.com
> Date: Tue, 22 Oct 2024 21:42:33 +0800
> 
> - Manually create a temporary file somewhere outside the repository;
>   I'll refer to its absolute file name as TEMP.
> 
> - Put the commit message for ORIG-REV into the temporary file.
> 
> - Modify that commit message to include the Unicode, or whatever.
> 
> - Prepend "amend! <sha1 of ORIG-REV>\n\n".  So for example:
> 
> --8<---------------cut here---------------start------------->8---
> amend! 212cf3125611b123707feac6f7ffd55a230bc568
> 
> Make all the entries in 'eshell-parse-argument-hook' named functions
> 
> * lisp/eshell/esh-arg.el (eshell-parse-number, eshell-parse-non-special)
> (eshell-parse-whitespace, eshell-parse-comment): New functions...
> (eshell-parse-argument-hook): ... use them.   אבגד ą ě č
> --8<---------------cut here---------------end--------------->8---
> 
> - Save the temporary file.
> 
> - Ensure there are no staged changes.
>   ('git reset' with no arguments should do it)
> 
> - git commit --allow-empty -F TEMP
> 
> - git rebase --autosquash -i ORIG-REV~1

This last step shows the following (again, indented 2 columns by me):

  pick bf73d7e Foobar with some Unicode אבגד ą ě č
  # pick d796890ee8cc77ac899954c3e94e5257c5f72615 amend! bf73d7e036c5d80cdd112f34255a0ab1ea697c07

  # Rebase 6c6ea73..d796890 onto 6c6ea73 (1 command)
  #
  # Commands:
  # p, pick = use commit
  # r, reword = use commit, but edit the commit message
  # e, edit = use commit, but stop for amending
  # s, squash = use commit, but meld into previous commit
  # f, fixup = like "squash", but discard this commit's log message
  # x, exec = run command (the rest of the line) using shell
  # d, drop = remove commit
  #
  # These lines can be re-ordered; they are executed from top to bottom.
  #
  # If you remove a line here THAT COMMIT WILL BE LOST.
  #
  # However, if you remove everything, the rebase will be aborted.
  #
  # Note that empty commits are commented out

And if I type "C-x #" to exit, without changing the above in any way
(since you didn't tell me to change anything), I'm back at ORIG-REV
with its original log message.  IOW, the editing of the commit log
message failed.




This bug report was last modified 104 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.