зеркало из https://github.com/microsoft/git.git
[PATCH] Fixed two bugs in git-cvsimport-script.
The git-cvsimport-script had a copule of small bugs that prevented me from importing a big CVS repository. The first was that it didn't handle removed files with a multi-digit primary revision number. The second was that it was asking the CVS server for "F" messages, although they were not handled. I also updated the documentation for that script to correspond to actual flags. Signed-off-by: David K?5gedal <davidk@lysator.liu.se> Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
Родитель
8b8840e046
Коммит
b092133103
|
@ -29,6 +29,10 @@ OPTIONS
|
||||||
currently, only the :local:, :ext: and :pserver: access methods
|
currently, only the :local:, :ext: and :pserver: access methods
|
||||||
are supported.
|
are supported.
|
||||||
|
|
||||||
|
-C <target-dir>::
|
||||||
|
The GIT repository to import to. If the directory doesn't
|
||||||
|
exist, it will be created. Default is the current directory.
|
||||||
|
|
||||||
-i::
|
-i::
|
||||||
Import-only: don't perform a checkout after importing. This option
|
Import-only: don't perform a checkout after importing. This option
|
||||||
ensures the working directory and cache remain untouched and will
|
ensures the working directory and cache remain untouched and will
|
||||||
|
@ -44,7 +48,7 @@ OPTIONS
|
||||||
|
|
||||||
-p <options-for-cvsps>::
|
-p <options-for-cvsps>::
|
||||||
Additional options for cvsps.
|
Additional options for cvsps.
|
||||||
The options '-x' and '-A' are implicit and should not be used here.
|
The options '-u' and '-A' are implicit and should not be used here.
|
||||||
|
|
||||||
If you need to pass multiple options, separate them with a comma.
|
If you need to pass multiple options, separate them with a comma.
|
||||||
|
|
||||||
|
@ -57,6 +61,9 @@ OPTIONS
|
||||||
-h::
|
-h::
|
||||||
Print a short usage message and exit.
|
Print a short usage message and exit.
|
||||||
|
|
||||||
|
-z <fuzz>::
|
||||||
|
Pass the timestamp fuzz factor to cvsps.
|
||||||
|
|
||||||
OUTPUT
|
OUTPUT
|
||||||
------
|
------
|
||||||
If '-v' is specified, the script reports what it is doing.
|
If '-v' is specified, the script reports what it is doing.
|
||||||
|
|
|
@ -190,7 +190,7 @@ sub conn {
|
||||||
$self->{'socketo'}->write("Root $repo\n");
|
$self->{'socketo'}->write("Root $repo\n");
|
||||||
|
|
||||||
# Trial and error says that this probably is the minimum set
|
# Trial and error says that this probably is the minimum set
|
||||||
$self->{'socketo'}->write("Valid-responses ok error Valid-requests Mode M Mbinary E F Checked-in Created Updated Merged Removed\n");
|
$self->{'socketo'}->write("Valid-responses ok error Valid-requests Mode M Mbinary E Checked-in Created Updated Merged Removed\n");
|
||||||
|
|
||||||
$self->{'socketo'}->write("valid-requests\n");
|
$self->{'socketo'}->write("valid-requests\n");
|
||||||
$self->{'socketo'}->flush();
|
$self->{'socketo'}->flush();
|
||||||
|
@ -702,7 +702,7 @@ while(<CVS>) {
|
||||||
push(@new,[$mode, $sha, $fn]); # may be resurrected!
|
push(@new,[$mode, $sha, $fn]); # may be resurrected!
|
||||||
}
|
}
|
||||||
unlink($tmpname);
|
unlink($tmpname);
|
||||||
} elsif($state == 9 and /^\s+(.+?):\d(?:\.\d+)+->(\d(?:\.\d+)+)\(DEAD\)\s*$/) {
|
} elsif($state == 9 and /^\s+(.+?):\d+(?:\.\d+)+->(\d+(?:\.\d+)+)\(DEAD\)\s*$/) {
|
||||||
my $fn = $1;
|
my $fn = $1;
|
||||||
$fn =~ s#^/+##;
|
$fn =~ s#^/+##;
|
||||||
push(@old,$fn);
|
push(@old,$fn);
|
||||||
|
|
Загрузка…
Ссылка в новой задаче