Reads data files created by clearexport tools and import elements into a VOB
ClearCase (administrative command)
During the import stage, you invoke clearimport within an existing VOB on the datafile created by clearexport_*. For each object processed by clearexport_* and entered in datafile, clearimport does one of the following things:
The user who invokes clearimport becomes the owner of the elements that clearimport creates. clearexport_* and clearimport use ClearCase magic files to determine which element type to use for each element clearimport creates. For more information on magic files and file-typing, see the cc.magic reference page.
If any of the original files were located in subdirectories, clearimport creates corresponding directory elements.
clearimport uses your view context to select the directory version into which it imports elements. However, when clearimport creates directory versions, it creates them on the main branch. The exceptions are as follows:
You must observe the following requirements and restrictions:
| Product | Extraction Command |
|---|---|
PVCS | get |
RCS | co |
SourceSafe | ss.exe |
SCCS | get |
PVCS and SCCS use the same command; make sure the correct one is in your path.
clearimport documents changes to the VOB by creating event records:
import file element event record, along with the standard create element event record, in the VOB database. The import file element event record is associated with the parent directory element, not with the new file element itself. clearimport creates the import event record only if the object is more than 24 hours old.
create version event record with the comment from the original version.
create symbolic link event record.
import file element event record with the current time. It stamps the create version and create element event records according to the original data unless you use the -nsetevent option.
NOTE: When clearimport creates a branch, the branch and version 0 of the element inherit the history information (user, group, and time stamp) of the version from which the branch sprouts.
created by importer or the comment given with the -comment option.
clearimport can skip certain versions or entire elements, which gives you some flexibility:
CAUTION: If you invoke clearimport with the -nsetevent option, it creates ClearCase versions that are newer than all the original files to be imported; thus, it is not restartable.
For each source version, clearimport does not create a corresponding version if it already exists on the target branch-that is, if it has the same time stamp (or a more recent one). However, even when clearimport bypasses version creation, it still updates the new version's metadata, such as version labels, using information from the source version.
By default, clearimport converts all file names to lower case. This is generally the simplest and most efficient way to import files when you use the MVFS option of case insensitive mode (the default). Converting file names on import mirrors the behavior of new files created in case-insensitive mode. For more information, see Administering ClearCase.
Use the -pcase option when you need to preserve the case of files being imported; for example, when you import files whose names differ only in case (for example, Makefile and makefile) and you have disabled case-insensitive mode.
clearimport prints an error when it cannot read an element version specified in the export data file. It creates version 0 of the unreadable element and continues to process the export datafile. Additionally, if clearimport has any difficulty importing any elements, it prints a list of such elements after it finishes.
Permissions Checking: To invoke clearimport, you must be the VOB owner or a member of the ClearCase group, unless you use the -nsetevent option. Locks: An error occurs if the target VOB is locked.
VERBOSITY OF OUTPUT. Default: clearimport prints a header for each kind of type creation (label, branch, attribute, and so on). When it creates directory elements, file elements, and VOB symbolic links, it prints a header as well as element names and version-IDs. When the import is completed, clearimport prints a message indicating that it has closed the directories.
CREATION OF IDENTICAL SUCCESSOR VERSIONS. Default: When you invoke clearimport on a datafile created by clearexport_ffile, it does not create a new version that is identical to its predecessor.
TRANSCRIPTION OF HISTORY INFORMATION. Default: The exporters extract historical information from each object and place it in the object's description in the datafile. The create version and create element event records created for the object by clearimport have the same information-user, group, and time stamp-as the original object.
NOTE: When clearimport creates a branch, the branch and version 0 of the element inherit the history information of the version from which the branch sprouts.
MASTERSHIP OF THE MAIN BRANCH. Default: Assigns mastership of the element's main branch to the VOB replica that masters the main branch.
PRESERVE CASE OF FILES. Default: clearimport converts all file names to lower case.
SPECIFYING A DESTINATION DIRECTORY. Default: clearimport imports elements into the current directory.
EVENT RECORDS AND COMMENTS. Default: clearimport attaches the comment "created by importer" to any directories created during the import process.
SPECIFYING THE DATA FILE. Default: None. You must specify the datafile on which you want to invoke clearimport.
c:\> net use * \\view\newview (set a view context)
Drive F: is now connected to \\view\newview.
The command completed successfully.
c:\> f:
f:\> cd newvob (go to VOB directory where data is to be imported)
f:\newvob> clearimport -identical -c "rick's import" c:\src\cvt_data (invoke clearimport)
c:\> net use y: \\view\view1
Drive Y: is now connected to \\view\view1.
The command completed successfully.
c:\> y:
y:\> clearimport -verbose -directory \newvob cvt_data
chtype, clearexport_ccase, clearexport_ffile, clearexport_pvcs, clearexport_rcs, clearexport_sccs, clearexport_ssafe, events_ccase, protect, rename
|
Feedback on the documentation in this site? We welcome any comments!
Copyright © 1999 by Rational Software Corporation. All rights reserved. |