Intel XENIX 286 Programmers Guide (86) - Tenox.tc

Intel XENIX 286 Programmers Guide (86) - Tenox.tc Intel XENIX 286 Programmers Guide (86) - Tenox.tc

09.06.2013 Views

XENIX Programming SCCS: Source Code Control System Listing the Deltas of a Version You can create a table showing the deltas required to create a given version by using the -1 option. The option causes the get command to create an 1-file that contains the SIDs of all deltas used to create the given version. The option is typically used to create a history of a given version's development. For example, the command get -1 s.demo.c creates a file named l.demo.c containing the deltas required to create the most recent version of demo.c. You can display the list of deltas required to create a version by using the -lp option. This option performs the same function as the -1 option, except that it copies the list to the standard output. For example, the command get -l p -r2.3 s.demo.c copies the list of deltas required to create version 2.3 of demo.c to the standard output. Note that the -1 option may be combined with the -g option to create a list of deltas without retrieving the actual version. Mapping Lines to Deltas You can map each line in a given version to its corresponding delta by using the -m option of the get command. The option causes each line in a g-file to be preceded by the SID of the delta that caused that line to be inserted. The SID is separated from the beginning of the line by a tab character. The option is typically used to review the history of each line in a given version. Naming Lines You can name each line in a given version with the current module name (i.e., the value of the 96M% keyword) by using the -n option of the get command. The option causes each line of the retrieved file to be preceded by the value of the %M% keyword and a tab character. The -n option is typically used to indicate that a given line is from the given file. When both the -m and -n options are specified, each line begins with the %M% keyword. 5-29

SCCS: Source Code Control System XENIX Programming Displaying a List of Differences You can display a detailed list of the differences between a new version of a file and the previous version by using the -p option of the delta com mand. The option causes the command to display the differences in a format sim ilar to the output of the XENIX diff command. Displaying File Information You can display information about a given version by using the -g command of the get option. The option suppresses the actual retrieval of a version and causes only the information about the version, such as the SID and size, to be displayed. The option is often used with the -r option to check for the existence of a given version. For example, the command get -g -r4.3 s.demo.c displays information about version 4.3 in the s-file s.demo.c. If the version does not exist, the command displays an error message. Removing a Delta You can remove a delta from an s-file by using the rmdel command. The command has the form rmdel -rSID s. filename where -rSID gives the SID of the delta to be removed, and s.filename is the name of the s-file from which the delta is to be removed. The delta must be the most recently created delta in the s-file. Furthermore, the user must have write permission in the directory containing the s-file and must either own the s-file or be the user who created the delta. For example, the command rmdel -r2.3 s.demo.c removes delta 2.3 from the s-file s.demo.c. The rmdel command will refuse to remove a protected delta, that is, a delta whose release number is below the current floor value, above the current ceiling value, or equal to a current locked value. The command will also refuse to remove a delta that is currently being edited. The rmdel command should be reserved for those cases in which incorrect, global changes were made to an s-file. Note that rmdel changes the type indicator of the given delta from "D" to "R". A type indicator defines the type of delta. 5-30

SCCS: Source Code Control System <strong>XENIX</strong> Programming<br />

Displaying a List of Differences<br />

You can display a detailed list of the differences between a new version of a file and the<br />

previous version by using the -p option of the delta com mand. The option causes the<br />

command to display the differences in a format sim ilar to the output of the <strong>XENIX</strong> diff<br />

command.<br />

Displaying File Information<br />

You can display information about a given version by using the -g command of the get<br />

option. The option suppresses the actual retrieval of a version and causes only the<br />

information about the version, such as the SID and size, to be displayed.<br />

The option is often used with the -r option to check for the existence of a given version.<br />

For example, the command<br />

get -g -r4.3 s.demo.c<br />

displays information about version 4.3 in the s-file s.demo.c. If the version does not<br />

exist, the command displays an error message.<br />

Removing a Delta<br />

You can remove a delta from an s-file by using the rmdel command. The command has<br />

the form<br />

rmdel -rSID s. filename<br />

where -rSID gives the SID of the delta to be removed, and s.filename is the name of the<br />

s-file from which the delta is to be removed. The delta must be the most recently<br />

created delta in the s-file. Furthermore, the user must have write permission in the<br />

directory containing the s-file and must either own the s-file or be the user who created<br />

the delta.<br />

For example, the command<br />

rmdel -r2.3 s.demo.c<br />

removes delta 2.3 from the s-file s.demo.c.<br />

The rmdel command will refuse to remove a protected delta, that is, a delta whose<br />

release number is below the current floor value, above the current ceiling value, or<br />

equal to a current locked value. The command will also refuse to remove a delta that is<br />

currently being edited.<br />

The rmdel command should be reserved for those cases in which incorrect, global<br />

changes were made to an s-file.<br />

Note that rmdel changes the type indicator of the given delta from "D" to "R". A type<br />

indicator defines the type of delta.<br />

5-30

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!