Re: How to make devs write better commit messages

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

 



On 6 December 2011 14:55, Joseph Huttner <huttnified@xxxxxxxxx> wrote:
> So I know that there is a somewhat standard format of commit messages
> in Git, which Linus outlines here:
>
> https://github.com/torvalds/subsurface/blob/master/README#L164
>
> Trouble is, when most people go to commit, the file that the editor
> opens has no reminder of how to write a proper commit message.  Often
> I find myself having to go back through the commit log, or consulting
> the above link.
>
> I propose two things:
>
> 1.  An optional flag in the Git config that, if set, shows the format
> of a typical commit message in your commit message template.
>
> 2.  The ability to modify this commit message template.  Many teams
> use automated tools to read commit messages and then do automated
> tasks based on that data, like comment an RT ticket.  Thus, developers
> need to be reminded of these team-specific settings as well.
>
> What are your thoughts?

Great idea! These templates would be stored in the Git repo, I assume?
Btw, there is 'commit.template' which you can use locally.

 I was wondering if it might be possible to somehow add project config
defaults to one's Git repo. It would be great to have something like
'commit.template' point to a file in the Git repo by default.
Currently, it doesn't seem possible to have a config parameter "point
to" a file or directory in the Git repo. Nor do I know of a way to
have the Git repo set a config parameter to a default value. Or is
this possible after all?
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]