# # Template Config file for cvs2p4 # # This version tries to have suitable defaults, and is intended as a # starting point for you to use in setting up your own configuration. # # $Id: //guest/richard_geiger/utils/cvs2p4/config.tmpl#11 $ # This flag is an experimental switch for better handling of # repositories that are actually "Plain RCS", i.e., not created by # CVS. # $PureRCS = 0; # p4 command location (If other than "/usr/local/bin/p4") # $P4 = "/usr/local/bin/p4"; # p4 command location (If other than "/usr/local/bin/p4d") # $P4D = "/usr/local/bin/p4d"; # Perforce server to use during the conversion. Must be "localhost:" # and some unused port number. THIS SHOULD NEVER BE POINTED AT A # PRODUCTION PERFORCE SERVER INSTANCE! # $P4PORT = "localhost:1680"; # Perforce server's P4ROOT # $P4ROOT = "$Convdir/p4root"; # The Perforce user who will own labels and depots created # $CONVUSER = "cvs2p4"; # The depot pathname for copied/linked RCS archive files. (The path # used will be $P4ROOT/$DEPOT/$CVS_MODULE/<filepath>). # # *** WARNING! ***: $DEPOT should be set to a path you will NEVER, # EVER consider using (for anything other than imported revisions) # within your Perforce depot. You should be safe as long as you # don't create a client workspace that maps $DEPOT. Instead, map # your converted files using the $P4_DEPOT path you choose (see # below). # $DEPOT = "depot/IMPORT"; # Whether or not to keep "cvs import"ed vendor branches in thier # own depot. Default is to just make the 1.1.1 branch another branch # in the same depot(s) the file(s) from all other branches end up in... # #$USE_IMPORT_DEPOT = "//import"; # %Depotmap allows the mapping different top-level directories # under $CVSROOT (these are the hash keys) into different Perforce depots # (These are the hash values). E.g., # #$Depotmap{"dir"} = "//dir"; # Perforce user name to use during the conversion. # This code defaults it to the user name of the user running # the conversion, but you can override that here if you want. # # (@pwent) = getpwuid($<); if ($#pwent < 7) { print STDERR "$Myname: can't get your passwd file entry.\n"; exit 1; } $P4USER = $pwent[0]; # Top of the module in the p4 depot namespace. If this does not start # with "//depot/", then a new depot will be defined in the converted # database; e.g., with this set to "//Test", a depot named "Test" with # map "Test/..." will be created. # $P4_DEPOT = "//depot/Test"; # This should be the $CVSROOT for the repository you are working with. # (But it must be a local pathname, not a remote CVS style CVSROOT!) # $CVS_ROOT = ""; # Top of the CVS module repository to convert # # (Typically, you'll use an absolute path, but it can also be relative # to where you execute the conversion commands from.) # if ($CVS_ROOT) { $CVS_MODULE = "$CVS_ROOT/<dir>"; } else { $CVS_MODULE = "<dir>"; } # Whether to copy (rather than link) the original RCS archives # into $P4ROOT/depot/IMPORT. This affects "dochanges" only. # $COPYIMPORT = 1; # Allow symlinks to directories in the top level of the RCS module. # Useful for partial converts of CVS modules, where you only want # certain subtrees, e.g., you have a cvs module "d" with: # # $CVSROOT/d/x # $CVSROOT/d/y # $CVSROOT/d/z # # ...and you only want to import d/x & d/z; you create # # $CVSROOT/D # $CVSROOT/D/x -> $CVSROOT/d/x # $CVSROOT/D/z -> $CVSROOT/d/z # # set CVS_MODULE to "D", and set this: # $SYM_SPECIAL = 1; # Files you don't want; Any files matching this regular expression # will not be imported. The matching is done on the *filename only*; # I.e., you probably want to use "^(.cvsignore|ignoremeto|andme),v\$" # to suppliy additional names, and you can't match based on directory # pathname components. # $IGNOREFILES = "^(.cvsignore),v\$"; # Name of the "head" codeline (which will become the "main" branch in # Perforce). Use "head" to get the cvs trunk, or another branch tag # name if you want that branch to become the "main" branch in # Perforce... # $TRUNKLINE = "head"; # Name for the "main" branch in Perforce. # $MAINNAME = "main"; # Conventional branch tag name suffix to remove when importing to # Perforce. (This is a netapp specific thing; our branch tags were # named <name>_BRANCH, but we wanted the "branches" in the Perforce # depot to be "$P4_DEPOT/<name>"). # #$BRANCH_FLASH = "_BRANCH"; # Whether to go all the way back to the first rev on the trunk. # (Otherwise, we just go back to the oldest ancestor rev of any # converted branch). # $ALLTHEWAYBACK = 1; # Whether to treat CVS tags on 1.1.1.1 revisions in CVS as if they # actually name revision "1.1". # # In some archives initialized with "cvs import", and subsequently # tagged, the tags for files which have not been revised since the # import will point at the 1.1.1.1 revision (which is on the "import" # branch). Normally (without this) cvs2p4 will model this, i.e., the # tag for such files will appear in the "import" branch. However, some # users may want to consider the file as having been tagged in the # "main" branch. Setting this option will make cvs2p4 treat the tag as # if it had named the 1.1 revision (which is, presumably, always # identical to the 1.1.1.1 revision after a "cvs import". Note that # repositories which have had several vendor drops could have tags # pointing to other revisions 1.1.1.{n>1}, and this will not help in # such situations! # $IMPORTTAGSPOOF = 1; # Setting the following variable to 1 will cause the converter to # wriate copies of the Perforce db.rev records for each file touched # by a change into the imported change description. This can be # valueable as a cross reference showing exactly what revision from a # converted CVS repository corresponds to each imported revision in # Perforce. # $REVRECS = 0; # Whether to ignore CVS tags that cannot be mapped into # CVS branch tags. (Affects the dolabels phase only) # $DISCARD_UNMAPPED_TAGS = 1; # Whether we're doing selected lines only... # # Typically, you might run "genmetadata" once with this set to 0, # which will print a list of all branch tag names encountered in the # repository. Then, you might want to fill in the <<LINES here file to # specify the list of codelines (branches) you want to import into # Perforce, set WANTLINES to 1, and rerun "genmetadata". # # Note that we also now support a branch exclusion list file # "exclude_branches", if you'd rather attack it from that direction... # $WANTLINES = 0; # If WANTLINES != 0, %WANTLINES contains a member for each codeline # wanted... # if ($WANTLINES) { $wantlines = <<LINES; $TRUNKLINE LINES @wantlines = split(/\n/, $wantlines); foreach $wantline (@wantlines) { $WANTLINES{$wantline} = 1; } } # DEADSTATE tells the converter what RCS state is to be considered # "dead". Since CVS defines this to be "dead", that's the default, and # you needn't muck with this if you're converting a real CVS # repository. But, if you're actually converting "raw RCS", and your # site uses something else as the RCS state for a "deleted" file, you # can specify that here: # $DEADSTATE = "dead"; # Whether to check for binary file revisions by extracting each # revision from RCS, and using the perl "-B <file>" operator, # regardless of the keyword expansion options in the RCS ,v file. # Turning this on will slow the conversion process down some, but may # help to correctly identify files which should be treated as binaries # in Perforce, especially if your binary files don't all have RCS # keyword expansion turned off, and if they cannot be comprehensivly # identified by the EXT list (see below). Set to "1" to enable. # $CHECKBIN = 0; # Pathnames (implicitly rooted at $CVS_MODULE/) to be explicitly # treated as being plain "text" (vs "ktext"): # $NOKEYEXP_PATHNAME = <<NAMES; NAMES @NOKEYEXP_PATHNAME = split(/\n/, $NOKEYEXP_PATHNAME); foreach my $nokeyexp_pathname (@NOKEYEXP_PATHNAME) { $NOKEYEXP_PATHNAME{$nokeyexp_pathname} = 1; } # Path to the RCS "co" command; only needed if you have "CHECKBIN" set true. # $CO = "/usr/bin/co"; # File extensions to considered to signify binary files, regardless of the # keyword expansion options in the RCS ,v files. # $EXT = <<EXTS; a bin bmp class coff com dll doc dvi dwarf exe fm gif gz ico jar jpg lib o obj pdf ps pyc tar xbm xls zip z EXTS @EXT = split(/\n/, $EXT); foreach my $ext (@EXT) { $EXT{$ext} = 1; } # Whether to make a spec depot (and, if so, what to call it): # $SPEC_DEPOT = "spec"; 1;
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#11 | 5676 | Richard Geiger |
Add $CONVUSER to set owner for label and depot specs create dby the conversion. |
||
#10 | 5668 | Richard Geiger |
REVRECS (mainly). cc: roger@icmanage.com, shiv@icmanage.com |
||
#9 | 5658 | Richard Geiger | want TRUNKLINE default "head" (not "trunk") now. | ||
#8 | 5655 | Richard Geiger | update to match test/config.test - RIP shemp. | ||
#7 | 5648 | Richard Geiger | Prep for rolling b6 release | ||
#6 | 5640 | Richard Geiger |
Better comments in the config files. Fix an asymtompatic bug in srcdiff. |
||
#5 | 5639 | Richard Geiger |
Changes to clarify what to use in WANTLINES to get the cvs trunk (Perforce "main", usually). |
||
#4 | 5599 | Richard Geiger | About to unleash 3.0 upon an unsuspecting world... | ||
#3 | 5597 | Richard Geiger |
Add news USE_IMPORT_DEPOT switch, to allow you to have cvs-import'ed revisions (the "vendor branch") end up in a different depot than locally-authored revisions. This should pretty much complete feature work in 3.0; |
||
#2 | 5576 | Richard Geiger |
Make the defaults better in config.tmpl; add .pyc as a binary extention in both versions. |
||
#1 | 5575 | Richard Geiger | split config file. | ||
//guest/richard_geiger/utils/cvs2p4/test/config | |||||
#30 | 5571 | Richard Geiger |
Fix the "NOKEYEXP_PATHNAME" mechanism... so that it works :-) |
||
#29 | 5570 | Richard Geiger | decruftification. | ||
#28 | 5569 | Richard Geiger |
Just a variable name change: NOEXC_PATHNAME in config is now NOKEYEXP_PATHNAME. |
||
#27 | 5555 | Richard Geiger | NOEXC_PATHNAME | ||
#26 | 5545 | Richard Geiger | nit checkpoint. | ||
#25 | 5542 | Richard Geiger | checkpointing progress. | ||
#24 | 5531 | Richard Geiger |
A significant checkpoint commit, with new improved handling of import vendor branches, and revisions present in main by virtue of multiple vendor drops to a file with no local mods. test/runtest works, with new refernece results pretty well scrutinized. |
||
#23 | 5490 | Richard Geiger | $Depotmap implemented. | ||
#22 | 5489 | Richard Geiger | New checkpoint; now has multi-mod exclude_* files. | ||
#21 | 5483 | Richard Geiger |
The latest formula... ...and a typo. |
||
#20 | 5467 | Richard Geiger |
checkpoint. Need to update the docs prior to release! |
||
#19 | 5442 | Richard Geiger |
A checkpoint commit on the way to a 2.6.0 release with the new IronPort inspired improvements. |
||
#18 | 5430 | Richard Geiger |
This is another "checkpoint" commit. It significantly rearranges how labels are done, so as to use a hueristic to divine label<->branch identifications. Not intended for release without further testing and tweakage! |
||
#17 | 4914 | Richard Geiger | Adds PureRCS switch. | ||
#16 | 4885 | Richard Geiger | Allow using a name other than "main" for the TRUNKLINE branch. | ||
#15 | 3594 | Richard Geiger | Changes for 2.3.5 | ||
#14 | 2586 | Richard Geiger |
Update the README to reflect my wandering ways. Lord I was born a travellin man Also, fix a few typos in the config file. Not planning on releasing just for these. |
||
#13 | 2061 | Richard Geiger |
changes for 2.3.2: - can adjust db hash bucket size; - Add $DEPOT config variable - Handle labels with '#' or '@' |
||
#12 | 1987 | Richard Geiger | Changes for 2.3.1 | ||
#11 | 1967 | Richard Geiger | Add new config item "DEADSTATE". | ||
#10 | 1964 | Richard Geiger | Add $TEXTTYPE and surrounding accoutrements. | ||
#9 | 1781 | Richard Geiger |
This change reintegrates cvs2p4 2.0 developement work (through 2.0b6) back into my mainline development. |
||
#8 | 1329 | Richard Geiger |
Fix the dochanges example in README to say "convdir" like the other examples; Remove extraneous ALLTHEWAYBACK=1; the slipped into the config file. Probably from listening to the WayBacks too much. http://www.waybacks.com |
||
#7 | 1206 | Richard Geiger |
Genericize the "p4 labels" test case, and beef up the comments describing $TRUNKLINE in the config file a bit. |
||
#6 | 1203 | Richard Geiger |
Fix bug where dolables couldn't cope with tag in which the revision for a file was a delete Add the IMPORTTAGSPOOF switch. |
||
#5 | 1054 | Richard Geiger | Tweak a note in the config template. | ||
#4 | 985 | Richard Geiger | Fix a couple of typos. | ||
#3 | 791 | Richard Geiger |
Update for a new release; my change-of-venue noted; desensitized to conflicting P4CONFIG. |
||
#2 | 179 | Richard Geiger | CHanges for 1.2.3 | ||
#1 | 130 | Richard Geiger |
CVS-to-Perforce converter. This is release 1.2.2 (first submit to the Perforce Public Depot) |