bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: yet another git trick


From: Bruno Haible
Subject: Re: yet another git trick
Date: Thu, 29 May 2008 01:55:04 +0200
User-agent: KMail/1.5.4

Hallo Paolo,

> Personally, I think this is a good alternative to making ChangeLog files 
> automatically from the VCS logs.
> 
> Drop it in .git/hooks/prepare-commit-msg and make it executable!

Interesting idea!

When I try your script, after adding a ChangeLog entry, it shows me an
editor buffer with this contents:

----------------------------------------------------------------------


 2008-05-28  Bruno Haible  <address@hidden>

        Support more platforms ACLs.
        * m4/acl.m4 (gl_FUNC_ACL): Add support for HP-UX.

# Please enter the commit message for your changes.
# (Comment lines starting with '#' will not be included)
# Explicit paths specified without -i nor -o; assuming --only paths...
# On branch master
# Changes to be committed:
#   (use "git reset HEAD <file>..." to unstage)
#
#       modified:   ChangeLog
#       modified:   m4/acl.m4
#
----------------------------------------------------------------------

It did fetch the newest ChangeLog correctly. But it adds a space before
each line of the ChangeLog entry. Tab after space - that does not smell good.

Also, since the gitweb summary view shows the first line of each commit
message, it would be useful to arrange things so that the first line of the
ChangeLog entry text (without leading tab) becomes the first line of the
git commit message. This means, instead of adding two blank lines, remove
the first line of the ChangeLog entry and the blank line afterwards and also
the next tab.

Bruno





reply via email to

[Prev in Thread] Current Thread [Next in Thread]