eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' & eval 'exec perl -S $0 $argv:q' if 0; # THE PRECEEDING STUFF EXECS perl via $PATH # -*-Fundamental-*- # $Id: //guest/doug_quist/utils/cvs2p4_meta/bin/revmap#1 $ # # Richard Geiger # require 5.000; use Carp; # ...or flounder. (This will fail unless 'perl' is a perl5!) $| = 1; ($Myname = $0) =~ s%^.*/%%; $Usage = <<LIT; $Myname: usage: $Myname [-map <mapfile>] <convdir> LIT sub usage { print STDERR $Usage; exit 1; } sub help { print STDERR <<LIT; $Usage $Myname is... LIT exit 1; } # option switch variables get defaults here... $Boolopt = 0; $Valopt = 0; $Mapfile = "revmap"; while ($#ARGV >= 0) { if ($ARGV[0] eq "-boolopt") { $Boolopt = 1; shift; next; } elsif ($ARGV[0] eq "-map") { shift; if ($ARGV[0] < 0) { &usage; } $Mapfile = $ARGV[0]; shift; next; } elsif ($ARGV[0] eq "-help") { &help; } elsif ($ARGV[0] =~ /^-/) { &usage; } if ($Args ne "") { $Args .= " "; } push(@Args, $ARGV[0]); shift; } if ($#Args ne 0) { &usage; } $Convdir = $Args[0]; chdir $Convdir || die "$Myname: can't chdir \"$Convdir\": $!"; $Convdir = `/bin/pwd`; chop $Convdir; chdir $Here || die "$Myname: can't chdir \"$Here\": $!"; $Revmap = "$Convdir/$Mapfile"; if (! dbmopen(REVMAP, $Revmap, 0444)) { print "$Myname: can't dbmopen \"$Revmap\": $!\n"; exit 1; } while (($key,$val) = each %REVMAP) { if ($Mapfile != "rrevmap") { $val =~ s/\001.*//; } print "$key $val\n"; } dbmclose REVMAP;
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#1 | 1769 | Doug Quist | Grab a copy of the wip in-case I want/need to tweak something during testing | ||
//guest/richard_geiger/utils/cvs2p4_meta/bin/revmap | |||||
#1 | 1636 | Richard Geiger | Branch for working on a direct-metadata generation verison of cvs2p4 | ||
//guest/richard_geiger/utils/cvs2p4/bin/revmap | |||||
#3 | 1407 | Richard Geiger |
=== Release 1.3.2 - Reduce the memory footprint of bin/genmetadata. Previously, it was holding and sorting a complete copy of the metadata file "in-core" (as well as a copy of all of the RCS revision tags data!). This adds up quick, and some users saw genmetadata gobbling memory voraciously (and in some cases being running out, causing thrashing and/or process termination by the OS). genmetadata now keeps the metadata in a temp file, (sorting it in primary-key-sized chunks), and the revision tag information in a db-backed hash. - Fix the label handling so that _all_ perforce revisions based on the labeled cvs revision are included in the generated labels. Previously, one of the N "correct" Perforce revisions were being tagged (effectively, at random). This stems from the fact that lazy copying and branching are explicit in Perforce, but implicit in CVS. I.e., the "#1" revision in a new Perforce branch _appears_ to be a separate entity (identical to the revision from which it was branched. This means that to use the converted labels, it will be up to _you_ to remember what labels go with what branches: but that's the way it is in CVS, too. - A minor change in revmap to have a meaningful usage message, and properly handle the new rrevmap format. - dochanges correctly deletes revmap database files for either *.db or *.pag/*.dat style databases. |
||
#2 | 1185 | Richard Geiger |
Changes for 1.3 (Labels!) |
||
#1 | 130 | Richard Geiger |
CVS-to-Perforce converter. This is release 1.2.2 (first submit to the Perforce Public Depot) |