public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jeff Law <law@redhat.com>
To: Richard Sandiford <richard.sandiford@arm.com>,
	"H.J. Lu"	 <hjl.tools@gmail.com>
Cc: paul@mad-scientist.net, GCC Development <gcc@gcc.gnu.org>
Subject: Re: Git ChangeLog policy for GCC Testsuite inquiry
Date: Mon, 03 Feb 2020 20:24:00 -0000	[thread overview]
Message-ID: <6bc259050138912ea9b973ca4f43df72cb1bb7d8.camel@redhat.com> (raw)
In-Reply-To: <mptpnev4i2a.fsf@arm.com>

On Mon, 2020-02-03 at 18:55 +0000, Richard Sandiford wrote:
> "H.J. Lu" <hjl.tools@gmail.com> writes:
> > On Fri, Jan 24, 2020 at 2:39 PM Paul Smith <paul@mad-scientist.net> wrote:
> > > On Fri, 2020-01-24 at 22:45 +0100, Jakub Jelinek wrote:
> > > > > > In my experience the output of git log is a total mess so cannot
> > > > > > replace ChangeLogs.  But we can well decide to drop ChangeLog for
> > > > > > the testsuite.
> > > > > 
> > > > > Well, glibc has moved to extracting them from git, building
> > > > > policies and scripts around that.  I'm pretty sure other
> > > > > significant projecs are also extracting their ChangeLogs from git.
> > > > > 
> > > > > We could do the same, selecting some magic date as the cutover
> > > > > point after which future ChangeLogs are extracted from GIT.  In
> > > > > fact, that's precisely what I'd like to see us do.
> > > > 
> > > > We don't have a tool that can do it, not even get the boilerplate
> > > > right. Yes, mklog helps, but it very often gets stuff wrong.  Not to
> > > > mention that the text what actually changed can't be generated very
> > > > easily.
> > > 
> > > I don't know if it counts as a significant project, but GNU make has
> > > been doing this for years.
> > > 
> > > What I did was take the existing ChangeLogs and rename them to
> > > ChangeLog.1 or whatever, then started with a new ChangeLog generated
> > > from scratch from Git messages.
> > > 
> > > I use the gnulib build-aux/gitlog-to-changelog script to do it.  It
> > > requires a little bit of discipline to get right; in particular you
> > > have to remember that the Git commit message will be indented 8 spaces
> > > in the ChangeLog, so you have to be careful that your commit messages
> > > wrap at char 70 (or less) in your Git commit.
> > > 
> > > If you have Git hooks you could enforce a bit of formatting; for
> > > example any line not indented by space must be <=70 chars long; this
> > > allows people to use long lines for formatted content if they indent it
> > > with a space or two.
> > > 
> > > Otherwise, it's the same as writing the ChangeLog and you only have to
> > > do it once.
> > > 
> > > Just to note, the above script simply transcribes the commit message
> > > into ChangeLog format.  It does NOT try to auto-generate ChangeLog-
> > > style content (files that changed, functions, etc.) from the Git diff
> > > or whatever.
> > > 
> > > There are a few special tokens you can add to your Git commit message
> > > that get reformated to special changelog tokens like "(tiny change)"
> > > etc.
> > > 
> > > As mentioned previously, it's very important that the commit message be
> > > provided as part of the code review, and it is very much fair game for
> > > review comments.  This is common practice, and a good idea because bad
> > > commit messages are always a bummer, ChangeLog or not.
> > > 
> > 
> > Libgcrypt includes ChangeLog entries in git commit messages:
> > 
> > http://git.gnupg.org/cgi-bin/gitweb.cgi?p=libgcrypt.git
> > 
> > In each patch, commit log starts with ChangeLog entries without leading
> > TABs followed by separator line with -- and then commit message.   They
> > have a script to extract ChangeLog for release.
> 
> How many people would we be catering for by generating changelogs at
> release time though?  It seems too low-level to be useful to users,
> and people wanting to track gcc development history at the source level
> would surely be better off using git (which e.g. makes it much easier to
> track changes to particular pieces of code).
> 
> Perhaps there are practical or policy reasons for not requiring everyone
> who wants to track gcc development history to build or install git.
> But if so, why not just include the output of "git log", with whatever
> options seem best?  (Probably --stat at least, to show the affected files.)
> 
> Like with the svn-to-git conversion, the less we change the way the
> history is presented, the less chance there is of something going wrong.
> And the idea is that git log should be informative enough for upstream
> developers, so surely it should be enough for others too.
I believe the ChangeLog is primarily a FSF requirement, hence
generating it from the SCM at release time seems reasonable.

ANd yes, even though I have been a regular ChangeLog user, I rely more
and more on the git log these days.

jeff

  reply	other threads:[~2020-02-03 20:24 UTC|newest]

Thread overview: 48+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CAGWvnyktjKVp-T9jrGUt_rmzgaoS0Z5N1OPP9oaOvk0Xehrb_Q@mail.gmail.com>
     [not found] ` <28d80650-26ec-04eb-65af-76151da4e411@redhat.com>
     [not found]   ` <CAGWvny=RM5cPi9VoJOKMoPNvgcybavT0CCcKSowxRNZwfrBqNw@mail.gmail.com>
     [not found]     ` <CADzB+2nLasW5mdFBWFd7xxXRLx8+UMnfXTwOYzU_x4c8=WcQRQ@mail.gmail.com>
2020-01-24 21:36       ` David Edelsohn
2020-01-24 21:45         ` Jeff Law
2020-01-24 22:38           ` Eric Botcazou
2020-01-24 22:39             ` Florian Weimer
2020-01-24 22:56             ` Jeff Law
2020-01-25  9:31               ` Jakub Jelinek
2020-01-25 10:53                 ` Paul Smith
2020-01-25 14:07                   ` H.J. Lu
2020-02-03 18:55                     ` Richard Sandiford
2020-02-03 20:24                       ` Jeff Law [this message]
2020-02-05 21:18                         ` Segher Boessenkool
2020-02-06  8:51                           ` Richard Sandiford
2020-02-06 13:37                             ` Segher Boessenkool
2020-02-06 13:01                           ` Jeff Law
2020-02-06 13:51                             ` Segher Boessenkool
2020-02-06 14:01                               ` Richard Biener
2020-02-06 14:40                                 ` Jonathan Wakely
2020-02-07 18:37                                   ` Tom Tromey
2020-02-07 21:41                                     ` Jason Merrill
2020-02-07 22:34                                       ` Tom Tromey
2020-02-08 16:50                                         ` Segher Boessenkool
2020-02-08 23:55                                           ` Andrew Pinski
2020-02-09 10:08                                             ` Segher Boessenkool
2020-02-10 17:51                                           ` Matthew Malcomson
2020-02-11  0:37                                             ` Segher Boessenkool
2020-02-06 22:25                                 ` Segher Boessenkool
2020-02-07  9:20                                   ` Richard Biener
2020-02-07 10:08                                     ` Jonathan Wakely
2020-02-07 23:17                                       ` Alan Modra
2020-02-08 19:58                                         ` Segher Boessenkool
2020-02-09 10:46                                           ` Jonathan Wakely
2020-02-09 17:49                                             ` Segher Boessenkool
2020-02-07 13:48                                     ` Segher Boessenkool
2020-02-07 13:56                                       ` Richard Earnshaw (lists)
2020-02-07 15:33                                         ` Segher Boessenkool
2020-02-07 15:43                                           ` Richard Earnshaw (lists)
2020-02-07 16:00                                             ` Segher Boessenkool
2020-02-10 13:09                                             ` Richard Biener
2020-02-10 17:27                                   ` Hans-Peter Nilsson
2020-02-06 14:56                             ` Jakub Jelinek
2020-02-06 16:18                               ` Segher Boessenkool
2020-02-06 16:25                                 ` Jakub Jelinek
2020-02-06 18:58                                 ` Jason Merrill
2020-02-06 23:10                                   ` Segher Boessenkool
2020-01-25 22:40               ` Nathan Sidwell
2020-01-26 14:59                 ` Jeff Law
2020-02-03 10:15                   ` Richard Earnshaw (lists)
2020-02-03 13:01                     ` Nathan Sidwell

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6bc259050138912ea9b973ca4f43df72cb1bb7d8.camel@redhat.com \
    --to=law@redhat.com \
    --cc=gcc@gcc.gnu.org \
    --cc=hjl.tools@gmail.com \
    --cc=paul@mad-scientist.net \
    --cc=richard.sandiford@arm.com \
    /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.
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).