diff options
author | Peter Palfrader <peter@palfrader.org> | 2009-04-20 08:24:31 +0000 |
---|---|---|
committer | weasel <weasel@bc3d92e2-beff-0310-a7cd-cc87d7ac0ede> | 2009-04-20 08:24:31 +0000 |
commit | a40fdfe25b3e4f6b7a4e6e3d5d3e4fa31ac9334f (patch) | |
tree | 9a9cd0709bdefc0f0099f07b1956ea9ed65bd24d /parse-git | |
parent | f1971e868a92a17a29187e7258870fd288b2c980 (diff) |
Support patch-author header per nick's request
git-svn-id: svn+ssh://asteria.noreply.org/svn/weaselutils/trunk@383 bc3d92e2-beff-0310-a7cd-cc87d7ac0ede
Diffstat (limited to 'parse-git')
-rwxr-xr-x | parse-git | 12 |
1 files changed, 10 insertions, 2 deletions
@@ -50,6 +50,7 @@ die ("Project is not a nice name.\n") unless defined $project; my $subject; my $who; my $date; +my $author; open (MAIL, $ARGV[1]) || die ("Cannot open $ARGV[1]: $!\n"); my @mail = <MAIL>; @@ -70,6 +71,9 @@ while (defined($line = shift @mail)) { } elsif ($chomped =~ m/^From: (.*)/) { $who = $1; next; + } elsif ($chomped =~ m/^Patch-Author: (.*)/) { + $author = $1; + next; } } @@ -91,7 +95,11 @@ my $at; if (defined $date) { $at = " at $date"; } -$subject =~ s/\[([^\]]*)\] /in $1: /; -print MAIL "$who$at $subject\n"; +my $by; +if (defined $author) { + $by = " by $by"; +} +$subject =~ s/\[([^\]]*)\] /to $1: /; +print MAIL "$who committed patch$by$at $subject\n"; close(MAIL); |