Subject: bug#64055: [WIP Patch] Enable editing commit messages - vc-git-modify-change-comment

From: Sean Whitton <[email-masked]>
Date: Fri, 18 Oct 2024 17:30:16 +0800

Hello,

On Fri 18 Oct 2024 at 12:14pm +03, Eli Zaretskii wrote:

> Definitely.  It is otherwise very hard to realize that the discussion
> of these changes happened in this particular bug.

Right, okay.

> That's definitely not what the comments and the implementation convey.
> And I then understand even less why the backend action was added for
> Git in the first place.

Hmm, I see what you mean.  I should have included more detail in the
commit message and/or comments.

>> > Btw, since CVS has an existing command-line option to amend the log
>> > message of a particular commit, I wonder whether the design that goes
>> > through a separate backend function which extracts the comment first
>> > is valid.
>>
>> We still need to extract the comment first so that the user has some
>> text to edit.
>
> Are we envisioning the user invoking this from anything other than a
> log buffer?  Why would someone want to do that?

I can imagine a few cases where it might be useful, but I don't think
that's the main point.

The main point is that parsing text out of the log view buffer is much
more error-prone.  For example, with a non-distributed VCS like CVS,
what if someone else has edited the comment in the meantime?  It makes
sense to fetch the latest known version instead of relying on buffer
text.

So, I hope that we will eventually completely replace
log-view-extract-comment.

-- 
Sean Whitton