From: Gerrit Pape Date: Thu, 7 Feb 2008 09:36:10 +0000 (+0000) Subject: cvsimport: have default merge regex also match beginning of commit message X-Git-Tag: v1.5.4.2~20 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/9386ecbb1cb0576f67da804f57dd96ffd62bb3c6?ds=inline;hp=--cc cvsimport: have default merge regex also match beginning of commit message The default value of @mergerx uses \W, which matches a non-word character; this means that commit messages like "Merging FOO" are not matched by default; using \b, which matches a word boundary, instead of \W fixes that. This change was suggested by Frédéric Brière through http://bugs.debian.org/463468 Signed-off-by: Gerrit Pape Signed-off-by: Junio C Hamano --- 9386ecbb1cb0576f67da804f57dd96ffd62bb3c6 diff --git a/git-cvsimport.perl b/git-cvsimport.perl index 5694978c46..9516242338 100755 --- a/git-cvsimport.perl +++ b/git-cvsimport.perl @@ -164,7 +164,7 @@ sub read_repo_config { our @mergerx = (); if ($opt_m) { - @mergerx = ( qr/\W(?:from|of|merge|merging|merged) (\w+)/i ); + @mergerx = ( qr/\b(?:from|of|merge|merging|merged) (\w+)/i ); } if ($opt_M) { push (@mergerx, qr/$opt_M/);