@@ -224,10 +224,10 @@ sub getFirstCommitBeforeRevision {
224
224
my $revision = shift ;
225
225
fatal " Invalid revision string: $revision " if $revision =~ / \D / ;
226
226
227
- my $time = eval { command_oneline(" log" , " --all" , " --format=format:%ci " , " --max-count=1" , " --grep" , " ^git-svn-id: .*\\\@ $revision \\ b" ) };
227
+ my $time = eval { command_oneline(" log" , " --all" , " --format=format:%ci " , " --max-count=1" , " --grep= ^git-svn-id: .*\\\@ $revision \\ b" ) };
228
228
return undef unless $time ;
229
229
230
- my $commit = eval { command_oneline(" log" , " --before" , $time , " --format=format:%H " , " --max-count=1" ) };
230
+ my $commit = eval { command_oneline(" log" , " --before= $time " , " --format=format:%H " , " --max-count=1" ) };
231
231
while (getSvnRevision($commit ) > $revision ) {
232
232
($commit ) = getParentCommits($commit );
233
233
}
@@ -244,7 +244,7 @@ sub getCommitFromRevision {
244
244
# are added. This corresponds to the git "empty tree".
245
245
return getGitEmptyTree() if $revision == 0;
246
246
247
- return eval { command_oneline(" log" , " --format=format:%H " , " --max-count=1" , " --grep" , " ^git-svn-id: .*\\\@ $revision \\ b" ) };
247
+ return eval { command_oneline(" log" , " --format=format:%H " , " --max-count=1" , " --grep= ^git-svn-id: .*\\\@ $revision \\ b" ) };
248
248
}
249
249
250
250
# Returns the commit of the given revision, accepting special SVN keywords,
@@ -256,7 +256,7 @@ sub getCommitFromSvnIdentifier {
256
256
my @files ;
257
257
@files = @_ unless $revision eq " BASE" ;
258
258
259
- my $commit = eval { command_oneline(" log" , " --format=format:%H " , " --max-count=1" , " --grep" , " ^git-svn-id: " , " --" , @files ) };
259
+ my $commit = eval { command_oneline(" log" , " --format=format:%H " , " --max-count=1" , " --grep= ^git-svn-id: " , " --" , @files ) };
260
260
($commit ) = getParentCommits($commit ) if $revision eq " PREV" ;
261
261
return $commit ;
262
262
}
@@ -274,7 +274,7 @@ sub getSvnRevision {
274
274
275
275
return 0 if $commit eq getGitEmptyTree();
276
276
277
- my $body = eval { command(" log" , " --format=format:%B " , " --max-count=1" , $commit , " --" , @files ) };
277
+ my $body = eval { command(" log" , " --format=format:%b " , " --max-count=1" , $commit , " --" , @files ) };
278
278
return undef unless $body ;
279
279
280
280
return $1 if $body =~ m / ^git-svn-id:\s +[^@] +\@ (\d +)\b / m ;
0 commit comments