On Thu, Oct 18, 2012 at 5:08 AM, Tim Starling tstarling@wikimedia.org wrote:
On 18/10/12 19:08, Antoine Musso wrote:
During our first weeks using git, we have been asking people to write nice summary lines since they are used in Gerrit email notifications and in git log. I wrote a basic guideline (which has been improved since) that people can be pointed at:
https://www.mediawiki.org/wiki/Git/Commit_message_guidelines
That's interesting. I usually don't put the bug number in the first line, because there's not enough room for it. There's barely enough room to fit in the most simplified summary of a change in 62 characters, and the bug number would take up 12, leaving you only 50.
Indeed. And actually, I've kind of gotten out of the habit of doing this as well. The "standard practice" is actually for people to do it in the footer of the message, along with things like the Change-Id and Signed-Off-By. For example:
''' Fixing some broken feature
This was broken because......
Bug: 12345 Change-Id: .... '''
I rather prefer this format, to be honest. And actually, Gerrit has a feature (we're not making use of, but we easily could if people are interested) where you can track those bug footer notes. We could easily add regexes for Bugzilla and RT (gerrit calls them "tracking ids") if that's something people would use.
-Chad