replace
Creates a new version of an element from an edited copy.
Format
replace element_name[/branch_path] [-from pathname] [-keep]
Description
replace creates a new version of an element by moving the reserved copy from
your working directory (or the file or directory specified by the -from option)
back into the current library, where it becomes the most recent generation in
the specified line of descent.
If the named element is not stored in the current library and you have a current
system model setting, the DSEE facility searches the current model for an
Element of the given name. If it finds a single Element block with the same
name, the DSEE facility resets your current library setting to the library
containing that Element's primary dependency and then performs the specified
operation.
Unless you use the -keep option, the DSEE facility deletes the copy in the
working or specified directory. When you issue replace against an element
that's being monitored, the DSEE facility tells you about the monitor.
After completing a replace operation, the DSEE facility returns the string
"element_name" has been replaced, generation [version] created
The replace command complements reserve, which reserves a line of descent and
copies the latest version in that line of descent to the working or specified
directory for modification. The replace command also replaces versions created
with merge -reserve, which merges two versions on different lines of descent of
one element; in this case, replace creates a new version and records the merger
in the history database.
When you replace an element, the DSEE facility assumes you've modified it, and
by default asks you to enter "the nature of your modifications" in an edit pad
it opens for that information. The DSEE facility seeds the replace edit pad
with the comments entered when the element was reserved. This includes the title
of the task that was current at the time of the reserve operation, unless this
information has been deleted.
If you're replacing the first (initial) version of the element, the edit pad
notes that the element was reserved for initial creation.
After completing a replace operation, the DSEE facility automatically notes the
replace event in the current task's transcript.
You can replace an element reserved by another user. This may happen when more
than one user is working on a copy of an element or branch version. The DSEE
facility reports the reservation and asks if you want to continue the replace
operation.
If you replace an element you've neglected to modify, the DSEE facility performs
the operation anyway, but returns a warning message.
Note that in general, the DSEE facility stores elements as text files, because
they usually contain only simple ASCII text. These elements are of file type
"uasc." Elements that contain control characters or other non-ASCII text
characteristics cannot be stored as "uasc" files. The DSEE facility stores
these elements in files of type "record." If you replace a line of descent of
an element stored as type "uasc" and the new version that will be created
requires storage as type "record" (because it is not ASCII text, because it
contains an unprintable character, or because the text doesn't end with a
linefeed character), the DSEE facility changes the element's storage type.
Before it does this, however, the DSEE facility issues a warning message and
asks you if you are certain that you want to do this. This precaution is taken
because "record" type files cannot be changed back to "uasc" type files later.
Options:
-from pathname Specifies an alternate source file for the new
version.
-keep Retains the source file.
-comment "text" Allows you to enter comments without generating an
edit pad.
-nq Suppresses comment queries; associates seeded comments
(if available) with the operation.