'\" et .TH PRS "1P" 2017 "IEEE/The Open Group" "POSIX Programmer's Manual" .\" .SH PROLOG This manual page is part of the POSIX Programmer's Manual. The Linux implementation of this interface may differ (consult the corresponding Linux manual page for details of Linux behavior), or the interface may not be implemented on Linux. .\" .SH NAME prs \(em print an SCCS file (\fBDEVELOPMENT\fP) .SH SYNOPSIS .LP .nf prs \fB[\fR-a\fB] [\fR-d \fIdataspec\fB] [\fR-r\fB[\fISID\fB]]\fI file\fR... .P prs \fB[\fR-e|-l\fB]\fR -c \fIcutoff \fB[\fR-d \fIdataspec\fB]\fI file\fR... .P prs \fB[\fR-e|-l\fB]\fR -r\fB[\fISID\fB] [\fR-d \fIdataspec\fB] \fIfile\fR... .fi .SH DESCRIPTION The .IR prs utility shall write to standard output parts or all of an SCCS file in a user-supplied format. .SH OPTIONS The .IR prs utility shall conform to the Base Definitions volume of POSIX.1\(hy2017, .IR "Section 12.2" ", " "Utility Syntax Guidelines", except that the .BR \-r option has an optional option-argument. This optional option-argument cannot be presented as a separate argument. The following options shall be supported: .IP "\fB\-d\ \fIdataspec\fR" 10 Specify the output data specification. The .IR dataspec shall be a string consisting of SCCS file .IR data .IR keywords (see .IR "Data Keywords") interspersed with optional user-supplied text. .IP "\fB\-r[\fISID\fB]\fR" 10 Specify the SCCS identification string (SID) of a delta for which information is desired. If no .IR SID option-argument is specified, the SID of the most recently created delta shall be assumed. .IP "\fB\-e\fP" 10 Request information for all deltas created earlier than and including the delta designated via the .BR \-r option or the date-time given by the .BR \-c option. .IP "\fB\-l\fP" 10 Request information for all deltas created later than and including the delta designated via the .BR \-r option or the date-time given by the .BR \-c option. .IP "\fB\-c\ \fIcutoff\fR" 10 Indicate the .IR cutoff date-time, in the form: .RS 10 .sp .RS 4 .nf \fIYY\fB[\fIMM\fB[\fIDD\fB[\fIHH\fB[\fIMM\fB[\fISS\fB]]]]]\fR .fi .P .RE .P For the .IR YY component, values in the range [69,99] shall refer to years 1969 to 1999 inclusive, and values in the range [00,68] shall refer to years 2000 to 2068 inclusive. .TP 10 .BR Note: It is expected that in a future version of this standard the default century inferred from a 2-digit year will change. (This would apply to all commands accepting a 2-digit year as input.) .P .P No changes (deltas) to the SCCS file that were created after the specified .IR cutoff date-time shall be included in the output. Units omitted from the date-time default to their maximum possible values; for example, .BR \-c\07502 is equivalent to .BR \-c\0750228235959 . .RE .IP "\fB\-a\fP" 10 Request writing of information for both removed\(emthat is, .IR delta .IR type =\c .IR R (see .IR "\fIrmdel\fR\^")\(em\c and existing\(emthat is, .IR delta .IR type =\c .IR D ,\(em\c deltas. If the .BR \-a option is not specified, information for existing deltas only shall be provided. .SH OPERANDS The following operand shall be supported: .IP "\fIfile\fR" 10 A pathname of an existing SCCS file or a directory. If .IR file is a directory, the .IR prs utility shall behave as though each file in the directory were specified as a named file, except that non-SCCS files (last component of the pathname does not begin with .BR s. ) and unreadable files shall be silently ignored. .RS 10 .P If exactly one .IR file operand appears, and it is .BR '\-' , the standard input shall be read; each line of the standard input shall be taken to be the name of an SCCS file to be processed. Non-SCCS files and unreadable files shall be silently ignored. .RE .SH STDIN The standard input shall be a text file used only when the .IR file operand is specified as .BR '\-' . Each line of the text file shall be interpreted as an SCCS pathname. .SH "INPUT FILES" Any SCCS files displayed are files of an unspecified format. .SH "ENVIRONMENT VARIABLES" The following environment variables shall affect the execution of .IR prs : .IP "\fILANG\fP" 10 Provide a default value for the internationalization variables that are unset or null. (See the Base Definitions volume of POSIX.1\(hy2017, .IR "Section 8.2" ", " "Internationalization Variables" the precedence of internationalization variables used to determine the values of locale categories.) .IP "\fILC_ALL\fP" 10 If set to a non-empty string value, override the values of all the other internationalization variables. .IP "\fILC_CTYPE\fP" 10 Determine the locale for the interpretation of sequences of bytes of text data as characters (for example, single-byte as opposed to multi-byte characters in arguments and input files). .IP "\fILC_MESSAGES\fP" 10 .br Determine the locale that should be used to affect the format and contents of diagnostic messages written to standard error. .IP "\fINLSPATH\fP" 10 Determine the location of message catalogs for the processing of .IR LC_MESSAGES . .SH "ASYNCHRONOUS EVENTS" Default. .SH STDOUT The standard output shall be a text file whose format is dependent on the data keywords specified with the .BR \-d option. .SS "Data Keywords" .P Data keywords specify which parts of an SCCS file shall be retrieved and output. All parts of an SCCS file have an associated data keyword. A data keyword may appear in a .IR dataspec multiple times. .P The information written by .IR prs shall consist of: .IP " 1." 4 The user-supplied text .IP " 2." 4 Appropriate values (extracted from the SCCS file) substituted for the recognized data keywords in the order of appearance in the .IR dataspec .P The format of a data keyword value shall either be simple (\c .BR 'S' ), in which keyword substitution is direct, or multi-line (\c .BR 'M' ). .P User-supplied text shall be any text other than recognized data keywords. A shall be specified by .BR '\et' and by .BR '\en' . When the .BR \-r option is not specified, the default .IR dataspec shall be: .sp .RS 4 .nf :PN::\en\en .fi .P .RE .P and the following .IR dataspec shall be used for each selected delta: .sp .RS 4 .nf :Dt:\et:DL:\enMRs:\en:MR:COMMENTS:\en:C: .fi .P .RE .TS center box tab(!); cB s s s s cB | cB | cB | cB | cB lB | l | c | lB | c. SCCS File Data Keywords _ Keyword!Data Item!File Section!Value!Format _ :Dt:!Delta information!Delta Table!\fRSee below*\fP!S :DL:!Delta line statistics!"!:Li:/:Ld:/:Lu:!S :Li:!Lines inserted by Delta!"!\fInnnnn\fR***!S :Ld:!Lines deleted by Delta!"!\fInnnnn\fR***!S :Lu:!Lines unchanged by Delta!"!\fInnnnn\fR***!S :DT:!Delta type!"!D or R!S :I:!SCCS ID string (SID)!"!\fRSee below**\fP!S :R:!Release number!"!\fInnnn\fR!S :L:!Level number!"!\fInnnn\fR!S :B:!Branch number!"!\fInnnn\fR!S :S:!Sequence number!"!\fInnnn\fR!S :D:!Date delta created!"!:Dy:/:Dm:/:Dd:!S :Dy:!Year delta created!"!\fInn\fR!S :Dm:!Month delta created!"!\fInn\fR!S :Dd:!Day delta created!"!\fInn\fR!S :T:!Time delta created!"!:Th:::Tm:::Ts:!S :Th:!Hour delta created!"!\fInn\fR!S :Tm:!Minutes delta created!"!\fInn\fR!S :Ts:!Seconds delta created!"!\fInn\fR!S :P:!Programmer who created Delta!"!\fIlogname\fR!S :DS:!Delta sequence number!"!\fInnnn\fR!S :DP:!Predecessor Delta sequence!"!\fInnnn\fR!S !number :DI:!Sequence number of deltas!"!:Dn:/:Dx:/:Dg:!S !included, excluded, or ignored :Dn:!Deltas included (sequence #)!"!:DS: :DS: .\|.\|.!S :Dx:!Deltas excluded (sequence #)!"!:DS: :DS: .\|.\|.!S :Dg:!Deltas ignored (sequence #)!"!:DS: :DS: .\|.\|.!S :MR:!MR numbers for delta!"!\fItext\fR!M :C:!Comments for delta!"!\fItext\fR!M :UN:!User names!User Names!\fItext\fR!M :FL:!Flag list!Flags!\fItext\fP!M :Y:!Module type flag!"!\fItext\fR!S :MF:!MR validation flag!"!yes \fRor\fP no!S :MP:!MR validation program name!"!\fItext\fR!S :KF:!Keyword error, warning flag!"!yes \fRor\fP no!S :KV:!Keyword validation string!"!\fItext\fR!S :BF:!Branch flag!"!yes \fRor\fP no!S :J:!Joint edit flag!"!yes \fRor\fP no!S :LK:!Locked releases!"!:R: .\|.\|.!S :Q:!User-defined keyword!"!\fItext\fR!S :M:!Module name!"!\fItext\fR!S :FB:!Floor boundary!"!:R:!S :CB:!Ceiling boundary!"!:R:!S :Ds:!Default SID!"!:I:!S :ND:!Null delta flag!"!yes \fRor\fP no!S :FD:!File descriptive text!Comments!\fItext\fR!M :BD:!Body!Body!\fItext\fR!M :GB:!Gotten body!"!\fItext\fR!M :W:!A form of \fIwhat\fP string!N/A!:Z::M:\et:I:!S :A:!A form of \fIwhat\fP string!N/A!:Z::Y: :M: :I::Z:!S :Z:!\fIwhat\fP string delimiter!N/A!\fR@(#)\fR!S :F:!SCCS filename!N/A!\fItext\fR!S :PN:!SCCS file pathname!N/A!\fItext\fR!S .TE .IP * 6 .BR :Dt: =\c .BR ":DT: :I: :D: :T: :P: :DS: :DP:" .IP ** 6 .BR ":R:.:L:.:B:.:S:" if the delta is a branch delta (\c .BR :BF: =\|=\c .BR yes ) .br .BR ":R:.:L:" if the delta is not a branch delta (\c .BR :BF: =\|=\c .BR no ) .IP *** 6 The line statistics are capped at 99\|999. For example, if 100\|000 lines were unchanged in a certain revision, .BR :Lu: shall produce the value 99\|999. .SH STDERR The standard error shall be used only for diagnostic messages. .SH "OUTPUT FILES" None. .SH "EXTENDED DESCRIPTION" None. .SH "EXIT STATUS" The following exit values shall be returned: .IP "\00" 6 Successful completion. .IP >0 6 An error occurred. .SH "CONSEQUENCES OF ERRORS" Default. .LP .IR "The following sections are informative." .SH "APPLICATION USAGE" None. .SH EXAMPLES .IP " 1." 4 The following example: .RS 4 .sp .RS 4 .nf prs -d "User Names for :F: are:\en:UN:" s.file .fi .P .RE .P might write to standard output: .sp .RS 4 .nf User Names for s.file are: xyz 131 abc .fi .P .RE .RE .IP " 2." 4 The following example: .RS 4 .sp .RS 4 .nf prs -d "Delta for pgm :M:: :I: - :D: By :P:" -r s.file .fi .P .RE .P might write to standard output: .sp .RS 4 .nf Delta for pgm main.c: 3.7 - 77/12/01 By cas .fi .P .RE .RE .IP " 3." 4 As a special case: .RS 4 .sp .RS 4 .nf prs s.file .fi .P .RE .P might write to standard output: .sp .RS 4 .nf s.file: <\fIblank line\fP> D 1.1 77/12/01 00:00:00 cas 1 000000/00000/00000 MRs: bl78-12345 bl79-54321 COMMENTS: this is the comment line for s.file initial delta <\fIblank line\fP> .fi .P .RE .P for each delta table entry of the .BR D type. The only option allowed to be used with this special case is the .BR \-a option. .RE .SH RATIONALE None. .SH "FUTURE DIRECTIONS" None. .SH "SEE ALSO" .IR "\fIadmin\fR\^", .IR "\fIdelta\fR\^", .IR "\fIget\fR\^", .IR "\fIwhat\fR\^" .P The Base Definitions volume of POSIX.1\(hy2017, .IR "Chapter 8" ", " "Environment Variables", .IR "Section 12.2" ", " "Utility Syntax Guidelines" .\" .SH COPYRIGHT Portions of this text are reprinted and reproduced in electronic form from IEEE Std 1003.1-2017, Standard for Information Technology -- Portable Operating System Interface (POSIX), The Open Group Base Specifications Issue 7, 2018 Edition, Copyright (C) 2018 by the Institute of Electrical and Electronics Engineers, Inc and The Open Group. In the event of any discrepancy between this version and the original IEEE and The Open Group Standard, the original IEEE and The Open Group Standard is the referee document. The original Standard can be obtained online at http://www.opengroup.org/unix/online.html . .PP Any typographical or formatting errors that appear in this page are most likely to have been introduced during the conversion of the source files to man page format. To report such errors, see https://www.kernel.org/doc/man-pages/reporting_bugs.html .