X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=dgit;h=6b1201e7aee73dbc46cdcaa89b3c0b72987f49ce;hb=423b18b5527db8ebda1a86c4c32d30d0a0248cdb;hp=724dba10ef557e79a9ad2ebb1ec47ccb5f82f917;hpb=17cbb0b93e661fa2f163b155fd4505b0e4b70647;p=dgit.git diff --git a/dgit b/dgit index 724dba10..6b1201e7 100755 --- a/dgit +++ b/dgit @@ -1995,7 +1995,14 @@ sub make_commit_text ($) { sub clogp_authline ($) { my ($clogp) = @_; my $author = getfield $clogp, 'Maintainer'; - $author =~ s#,.*##ms; + if ($author =~ m/^[^"\@]+\,/) { + # single entry Maintainer field with unquoted comma + $author = ($& =~ y/,//rd).$'; # strip the comma + } + # git wants a single author; any remaining commas in $author + # are by now preceded by @ (or "). It seems safer to punt on + # "..." for now rather than attempting to dequote or something. + $author =~ s#,.*##ms unless $author =~ m/"/; my $date = cmdoutput qw(date), '+%s %z', qw(-d), getfield($clogp,'Date'); my $authline = "$author $date"; $authline =~ m/$git_authline_re/o or