|
|
get -p causes the retrieved text to be written to the standard output rather than to a g-file. In addition, all output normally directed to the standard output (such as the SID of the version retrieved and the number of lines retrieved) is directed instead to the standard error. get -p is used, for example, to create a g-file with an arbitrary name, as in
$ get -p s.abc > arbitrary file name
get -s suppresses output normally directed to the standard output, such as the SID of the retrieved version and the number of lines retrieved, but it does not affect messages normally directed to the standard error. get -s is used to prevent nondiagnostic messages from appearing on the user's terminal and is often used with -p to pipe the output, as in
$ get -p -s s.abc | pg
get -g prints the SID on standard output and there is no retrieval of the SCCS file. This is useful in several ways. For example, to verify a particular SID in an SCCS file
$ get -g -r4.3 s.abcoutputs the SID 4.3 if it exists in the SCCS file s.abc or an error message if it does not. Another use of get -g is in regenerating a p.file that may have been accidentally destroyed, as in
$ get -e -g s.abc
get -l causes SCCS to create l.file in the current directory with mode 444 (read-only for owner, group, and other) and owned by the real user. The l.file contains a table (whose format is described on get(CP)). showing the deltas used in constructing a particular version of the SCCS file. For example
$ get -r2.3 -l s.abcgenerates an l.file showing the deltas applied to retrieve version 2.3 of s.abc. Specifying p with -l, as in
$ get -lp -r2.3 s.abccauses the output to be written to the standard output rather than to l.file. get -g can be used with -l to suppress the retrieval of the text.
get -m identifies the changes applied to an SCCS file. Each line of the g-file is preceded by the SID of the delta that caused the line to be inserted. The SID is separated from the text of the line by a tab character.
get -n causes each line of a g-file to be preceded by the value of the %M% ID keyword and a tab character. This is most often used in a pipeline with grep(C). For example, to find all lines that match a given pattern in the latest version of each SCCS file in a directory, the following may be executed:
$ get -p -n -s directory | grep pattern
If both -m and -n are specified, each line of the g-file is preceded by the value of the %M% ID keyword and a tab (this is the effect of -n) and is followed by the line in the format produced by -m.
Because use of -m and/or -n causes the contents of the g-file to be modified, such a g-file must not be used for creating a delta. Therefore, neither -m nor -n may be specified together with get -e. See the get(CP) page.