Removes the name of an element or VOB symbolic link from a directory version
ClearCase (cleartool subcommand), Attache (command)
By default, a name can be removed from a directory only if that directory is checked out. rmname appends an appropriate line to the directory's checkout comment.
rmname modifies one or more checked-out directories by removing the names of elements and/or VOB symbolic links. Old versions of the directories do not change; the names continue to be cataloged in the old versions.
To remove a name from a checked-in directory version, you can use the -nco option. For example, you may want to remove an old symbolic link that points to a file that has been removed. You must be the VOB owner or a member of the ClearCase group to use this option, and the VOB must not be replicated.
In Attache, for all successfully removed names in the view, any corresponding read-only local files and directories are deleted in the workspace; local writable files, including any in a directory's subtrees, cause a confirming query to be issued.
In a snapshot view, this command implicitly executes an update operation on the affected elements.
Example: Suppose you checked out version 3 of a directory named a.dir. Only your view or workspace sees this directory version while it is checked out. The command rmname foo.c deletes the name foo.c from the checked-out version of the directory and from your Attache workspace, but leaves references to foo.c in earlier versions (if any) intact. When you check in the directory, all views can access the new version 4, which does not include foo.c.
Keep the following points in mind:
To restore a directory entry for an element that has been removed with rmname, use the ln command to create a VOB hard link to the element's entry in any previous version of the directory. For example:
cmd-context checkout src | (checkout parent directory) |
cmd-context rmname src\msg.c | (oops!) |
cmd-context ln src@@\main\LATEST\msg.c src\msg.c | (restore deleted name) |
If there are no entries for the element in any previous version of the directory, the element is orphaned; ClearCase or Attache has moved it to its VOB's lost+found directory. You can move/rename the element to its proper location with the cleartool or Attache mv command. (You cannot use ln to link elements that are in the lost+found directory.)
Permissions Checking: No special permissions required if directory is checked out; see checkout permissions. To use the -nco option, you must be VOB owner or a member of the ClearCase group. See the permissions reference page.
Locks: An error occurs if any of the following objects are locked: VOB.
EVENT RECORDS AND COMMENTS. Default: -nc. Creates one or more event records, with commenting controlled by your home directory's .clearcase_profile file (ClearCase) or your remote home directory's .clearcase_profile file (Attache). See CUSTOMIZING COMMENT HANDLING in the comments reference page. Comments can be edited with chevent.
REMOVING A NAME FROM A CHECKED-IN DIRECTORY VERSION. Default: You must check out a directory to remove a name and/or VOB symbolic link from it.
SPECIFYING THE NAMES TO BE REMOVED. Default: None.
Examples including wildcards or quoting are written for use in cleartool interactive mode. If you use cleartool single-command mode, you may need to change the wildcards and quoting to make your command interpreter process the command appropriately.
In cleartool single-command mode, cmd-context represents the command interpreter prompt. In cleartool interactive mode, cmd-context represents the interactive cleartool prompt. In Attache, cmd-context represents the workspace prompt.
NOTE: Examples assume that the current working directory is checked out.
cmd-context rmname util.c
Removed "util.c".
cmd-context rmname subd
cleartool: Warning: Object "subd" no longer referenced.
Object moved to vob lost+found as
"subd.5a200007ed11f0d709066505efe922a8".
Removed "subd".
cmd-context rmname -nco -force .@@\main\2\hello.h
Removed ".@@\main\2\hello.h".
|
Feedback on the documentation in this site? We welcome any comments!
Copyright © 1999 by Rational Software Corporation. All rights reserved. |