summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 9a5e407)
raw | patch | inline | side by side (parent: 9a5e407)
author | Martin Langhoff <martin@catalyst.net.nz> | |
Mon, 8 Jan 2007 06:43:39 +0000 (19:43 +1300) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Mon, 8 Jan 2007 11:01:16 +0000 (03:01 -0800) |
This makes the earlier "wait for 10 minutes before importing" safety
overridable with "-a(ll)" flag, and adds necessary documentation.
Signed-off-by: Martin Langhoff <martin@catalyst.net.nz>
Signed-off-by: Junio C Hamano <junkio@cox.net>
overridable with "-a(ll)" flag, and adds necessary documentation.
Signed-off-by: Martin Langhoff <martin@catalyst.net.nz>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Documentation/git-cvsimport.txt | patch | blob | history | |
git-cvsimport.perl | patch | blob | history |
index d21d66bfebe368c034afdabf79e8f143813e619d..6deee94bd3fed61f1f1340c88c5fea9bfb86684e 100644 (file)
Print a short usage message and exit.
-z <fuzz>::
- Pass the timestamp fuzz factor to cvsps.
+ Pass the timestamp fuzz factor to cvsps, in seconds. If unset,
+ cvsps defaults to 300s.
-s <subst>::
Substitute the character "/" in branch names with <subst>
CVS by default uses the unix username when writing its
commit logs. Using this option and an author-conv-file
in this format
+
+-a::
+ Import all commits, including recent ones. cvsimport by default
+ skips commits that have a timestamp less than 10 minutes ago.
+
---------
exon=Andreas Ericsson <ae@op5.se>
diff --git a/git-cvsimport.perl b/git-cvsimport.perl
index 26867751d76f0a86bf406274bd916191d3a5bdbd..a86ee3cb18ce2d182608c4ce360d4b98844d3bad 100755 (executable)
--- a/git-cvsimport.perl
+++ b/git-cvsimport.perl
$SIG{'PIPE'}="IGNORE";
$ENV{'TZ'}="UTC";
-our ($opt_h,$opt_o,$opt_v,$opt_k,$opt_u,$opt_d,$opt_p,$opt_C,$opt_z,$opt_i,$opt_P, $opt_s,$opt_m,$opt_M,$opt_A,$opt_S,$opt_L);
+our ($opt_h,$opt_o,$opt_v,$opt_k,$opt_u,$opt_d,$opt_p,$opt_C,$opt_z,$opt_i,$opt_P, $opt_s,$opt_m,$opt_M,$opt_A,$opt_S,$opt_L, $opt_a);
my (%conv_author_name, %conv_author_email);
sub usage() {
Usage: ${\basename $0} # fetch/update GIT from CVS
[-o branch-for-HEAD] [-h] [-v] [-d CVSROOT] [-A author-conv-file]
[-p opts-for-cvsps] [-C GIT_repository] [-z fuzz] [-i] [-k] [-u]
- [-s subst] [-m] [-M regex] [-S regex] [CVS_module]
+ [-s subst] [-a] [-m] [-M regex] [-S regex] [CVS_module]
END
exit(1);
}
}
$opt_o ||= "origin";
$opt_s ||= "-";
+$opt_a ||= 0;
+
my $git_tree = $opt_C;
$git_tree ||= ".";
$state = 11;
next;
}
- if ( $starttime - 300 - (defined $opt_z ? $opt_z : 300) <= $date) {
+ if (!$opt_a && $starttime - 300 - (defined $opt_z ? $opt_z : 300) <= $date) {
# skip if the commit is too recent
# that the cvsps default fuzz is 300s, we give ourselves another
# 300s just in case -- this also prevents skipping commits