You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Chuck Houpt <ch...@habilis.net> on 2007/04/19 12:28:35 UTC

[PATCH] Add optional log headline to subject in commit-email.pl

Hi,

Commit-email.pl only displays the revision and directory in commit 
email subjects, but I think it's often useful to include a log 
headline (first line of log message) in the subject. This makes it 
easy to browse commits, and quickly decide which email needs 
attention.

For example, from the following two commits, it's not clear which 
change is more important or interesting.

Subject: r255 - project/code
Subject: r256 - project/code

However, with the log headline, it's clear the second commit is more 
"interesting." :-)

Subject: project/code: Fixed spelling typos in comments.
Subject: project/code: Converted all code from C to Algol 68.

Attached is a patch and draft log message. Questions and comments welcome.

Thanks - Chuck

[[[
Add new --headline option to include log headline in subject.

The new --headline command-line option formats the subject line
to include the first line of the log message rather then
the revision number. The scripts default behavior is unchanged.

Patch by: Chuck Houpt <ch...@habilis.net>

* tools/hook-scripts/commit-email.pl.in
   (headline): New option.
   (opt_to_hash_key): Add --headline item.
   (): Add processing for --headline command-line option.
   (log_summary): Use first line or max 77 chars from log.
   (subject_base): For headline, use dirs and log summary.
   (usage): Note new option.
]]]