This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Commit messages and the move to git


On Mon, Nov 04, 2019 at 01:43:17PM +0100, Martin Jambor wrote:
> On Mon, Nov 04 2019, Richard Earnshaw (lists) wrote:
> > Some tools, particularly gitk or git log --oneline, can use one-line 
> > summaries from a commit's log message when listing commits.  It would be 
> > nice if we could start adopting a style that is compatible with this, so 
> > that in future commits are summarized in a useful way.
> 
> ...
> 
> > The normal convention in git is that the one line summary is essentially 
> > the subject line of the email message that describes the patch and is 
> > then followed by a blank line before the body of the commit message.
> >
> 
> I wholeheartedly agree.  Thanks to everyone already doing this and
> everyone else, please just start, adding a summary line takes just
> minimal effort.

Making a good subject is work and takes time, just like making a good
commit message, just like making a good patch.

The effort is worth it for at least two reasons:

1) More people read the commit message than write it, and this balance
shifts much further towards "read" if you consider the commit history
instead of just the patch submissions.

2) Being forced to describe your patches often makes you find problems
with them, or more generally, can make you actually understand what you
are doing ;-)


Segher


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]