From: Jim Porter <jporterbugs@gmail.com>
To: John Yates <john@yates-sheets.org>
Cc: emacs-devel@gnu.org
Subject: Re: New Git hooks for checking file names in commit messages
Date: Fri, 21 Apr 2023 09:44:55 -0700 [thread overview]
Message-ID: <e30f6b1e-6e48-2cee-d92b-e8e828000952@gmail.com> (raw)
In-Reply-To: <CAJnXXoijRDHvc6FUjabRLCmFQkF66hHdS7108-t_z6oYWCgN7w@mail.gmail.com>
On 4/21/2023 5:05 AM, John Yates wrote:
> On Fri, Apr 21, 2023 at 12:55 AM Jim Porter <jporterbugs@gmail.com> wrote:
>>
>> This also means that if you want to use a "*" for a bulleted list of
>> sentences, you should do something to make it not look like a file
>> entry. For example, " *" is ok.
>
> I am not wild about this change in commit message syntax. It clashes
> with all my other uses of git.
It's not a change in syntax (at least, it's not *intended* to change the
syntax). Commit messages for Emacs should all use the GNU Changelog
format so that they can be imported into the actual ChangeLog files.
These then get used to update etc/AUTHORS via the admin/authors.el
script, which looks at the file entries in the ChangeLog files.[1]
This ended up being a problem for Eli when preparing the Emacs 29
prerelease tarball, since there were a bunch of incorrect commit
messages that required several hours of manual intervention to fix.
(Since I was one of the people Eli emailed off-list to inform us that
we'd made these errors, I thought I should take some time to help
prevent this issue in the future.)
I tried to be as lenient as possible with the Git hooks so that they
only catch things that would be a problem for admin/authors.el, though
there are some small differences regarding multi-line lists of files.
> Do you allow more than one file on a bulleted line?
Yes. admin/authors.el allows this, so the Git hooks also allow it. (I
don't personally like it though.)
In principle, we could copy over the admin/authors.el heuristic though:
a line beginning with "*" starts a file entry *only if there's a ":"
somewhere following it, up to the next whitespace-only line*. This would
help avoid some false positives, but it also fails to catch errors where
committers forgot to add the ":", which I saw on several occasions when
looking over historical commits.
[1] That's a bit indirect (you could update etc/AUTHORS from the git
logs directly), but it lets maintainers modify the ChangeLog if
necessary before updating etc/AUTHORS, e.g. to fix authorship of a
change or to remove entries if they were backed out for some reason.
next prev parent reply other threads:[~2023-04-21 16:44 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-21 4:55 New Git hooks for checking file names in commit messages Jim Porter
2023-04-21 12:05 ` John Yates
2023-04-21 16:44 ` Jim Porter [this message]
2023-04-21 17:44 ` Jim Porter
2023-04-22 6:11 ` Eli Zaretskii
2023-04-22 6:59 ` Jim Porter
2023-04-22 7:51 ` Eli Zaretskii
2023-04-22 19:44 ` Jim Porter
2023-04-22 23:21 ` John Yates
2023-04-21 13:57 ` Alan Mackenzie
2023-04-21 15:05 ` Eli Zaretskii
2023-04-21 15:38 ` Arsen Arsenović
2023-04-21 15:50 ` Eli Zaretskii
2023-04-21 16:20 ` Arsen Arsenović
2023-04-21 17:44 ` Eli Zaretskii
2023-04-21 17:50 ` Arsen Arsenović
2023-04-22 6:16 ` Eli Zaretskii
2023-04-21 18:25 ` Andreas Schwab
2023-04-21 19:03 ` Björn Bidar
2023-04-21 19:53 ` Jim Porter
2023-04-22 7:03 ` Eli Zaretskii
2023-04-22 19:52 ` Jim Porter
2023-04-23 6:11 ` Eli Zaretskii
2023-04-23 7:07 ` Jim Porter
2023-04-23 7:37 ` Eli Zaretskii
2023-04-23 19:15 ` Jim Porter
2023-04-23 19:24 ` Eli Zaretskii
2023-04-23 7:19 ` Jim Porter
2023-04-23 7:39 ` Eli Zaretskii
2023-04-23 9:51 ` Björn Bidar
2023-04-22 23:55 ` Dmitry Gutov
2023-04-23 5:36 ` Eli Zaretskii
2023-04-23 9:47 ` Björn Bidar
2023-04-21 16:39 ` Jim Porter
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=e30f6b1e-6e48-2cee-d92b-e8e828000952@gmail.com \
--to=jporterbugs@gmail.com \
--cc=emacs-devel@gnu.org \
--cc=john@yates-sheets.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).