1PRS(1P) POSIX Programmer's Manual PRS(1P)
2
3
4
6 This manual page is part of the POSIX Programmer's Manual. The Linux
7 implementation of this interface may differ (consult the corresponding
8 Linux manual page for details of Linux behavior), or the interface may
9 not be implemented on Linux.
10
12 prs - print an SCCS file (DEVELOPMENT)
13
15 prs [-a][-d dataspec][-r[SID]] file...
16
17
18
19 prs [ -e| -l] -c cutoff [-d dataspec] file...
20
21
22
23 prs [ -e| -l] -r[SID][-d dataspec]file...
24
25
27 The prs utility shall write to standard output parts or all of an SCCS
28 file in a user-supplied format.
29
31 The prs utility shall conform to the Base Definitions volume of
32 IEEE Std 1003.1-2001, Section 12.2, Utility Syntax Guidelines, except
33 that the -r option has an optional option-argument. This optional
34 option-argument cannot be presented as a separate argument. The follow‐
35 ing options shall be supported:
36
37 -d dataspec
38 Specify the output data specification. The dataspec shall be a
39 string consisting of SCCS file data keywords (see Data Keywords
40 ) interspersed with optional user-supplied text.
41
42 -r[SID]
43 Specify the SCCS identification string (SID) of a delta for
44 which information is desired. If no SID option-argument is spec‐
45 ified, the SID of the most recently created delta shall be
46 assumed.
47
48 -e Request information for all deltas created earlier than and
49 including the delta designated via the -r option or the date-
50 time given by the -c option.
51
52 -l Request information for all deltas created later than and
53 including the delta designated via the -r option or the date-
54 time given by the -c option.
55
56 -c cutoff
57 Indicate the cutoff date-time, in the form:
58
59
60 YY[MM[DD[HH[MM[SS]]]]]
61
62 For the YY component, values in the range [69,99] shall refer to years
63 1969 to 1999 inclusive, and values in the range [00,68] shall refer to
64 years 2000 to 2068 inclusive.
65
66 Note:
67 It is expected that in a future version of IEEE Std 1003.1-2001
68 the default century inferred from a 2-digit year will change.
69 (This would apply to all commands accepting a 2-digit year as
70 input.)
71
72
73 No changes (deltas) to the SCCS file that were created after the speci‐
74 fied cutoff date-time shall be included in the output. Units omitted
75 from the date-time default to their maximum possible values; for exam‐
76 ple, -c 7502 is equivalent to -c 750228235959.
77
78 -a Request writing of information for both removed-that is, delta
79 type= R (see rmdel )- and existing-that is, delta type= D,-
80 deltas. If the -a option is not specified, information for
81 existing deltas only shall be provided.
82
83
85 The following operand shall be supported:
86
87 file A pathname of an existing SCCS file or a directory. If file is a
88 directory, the prs utility shall behave as though each file in
89 the directory were specified as a named file, except that non-
90 SCCS files (last component of the pathname does not begin with
91 s.) and unreadable files shall be silently ignored.
92
93 If exactly one file operand appears, and it is '-', the standard input
94 shall be read; each line of the standard input shall be taken to be the
95 name of an SCCS file to be processed. Non-SCCS files and unreadable
96 files shall be silently ignored.
97
98
100 The standard input shall be a text file used only when the file operand
101 is specified as '-' . Each line of the text file shall be interpreted
102 as an SCCS pathname.
103
105 Any SCCS files displayed are files of an unspecified format.
106
108 The following environment variables shall affect the execution of prs:
109
110 LANG Provide a default value for the internationalization variables
111 that are unset or null. (See the Base Definitions volume of
112 IEEE Std 1003.1-2001, Section 8.2, Internationalization Vari‐
113 ables for the precedence of internationalization variables used
114 to determine the values of locale categories.)
115
116 LC_ALL If set to a non-empty string value, override the values of all
117 the other internationalization variables.
118
119 LC_CTYPE
120 Determine the locale for the interpretation of sequences of
121 bytes of text data as characters (for example, single-byte as
122 opposed to multi-byte characters in arguments and input files).
123
124 LC_MESSAGES
125 Determine the locale that should be used to affect the format
126 and contents of diagnostic messages written to standard error.
127
128 NLSPATH
129 Determine the location of message catalogs for the processing of
130 LC_MESSAGES .
131
132
134 Default.
135
137 The standard output shall be a text file whose format is dependent on
138 the data keywords specified with the -d option.
139
140 Data Keywords
141 Data keywords specify which parts of an SCCS file shall be retrieved
142 and output. All parts of an SCCS file have an associated data keyword.
143 A data keyword may appear in a dataspec multiple times.
144
145 The information written by prs shall consist of:
146
147 1. The user-supplied text
148
149 2. Appropriate values (extracted from the SCCS file) substituted for
150 the recognized data keywords in the order of appearance in the
151 dataspec
152
153 The format of a data keyword value shall either be simple ( 'S' ), in
154 which keyword substitution is direct, or multi-line ( 'M' ).
155
156 User-supplied text shall be any text other than recognized data key‐
157 words. A <tab> shall be specified by '\t' and <newline> by '\n' . When
158 the -r option is not specified, the default dataspec shall be:
159
160
161 :PN::\n\n
162
163 and the following dataspec shall be used for each selected delta:
164
165
166 :Dt:\t:DL:\nMRs:\n:MR:COMMENTS:\n:C:
167
168 SCCS File Data Keywords
169 Keyword Data Item File Section Value Format
170 :Dt: Delta information Delta Table See below* S
171 :DL: Delta line statistics " :Li:/:Ld:/:Lu: S
172 :Li: Lines inserted by Delta " nnnnn*** S
173 :Ld: Lines deleted by Delta " nnnnn*** S
174 :Lu: Lines unchanged by Delta " nnnnn*** S
175 :DT: Delta type " D or R S
176 :I: SCCS ID string (SID) " See below** S
177 :R: Release number " nnnn S
178 :L: Level number " nnnn S
179 :B: Branch number " nnnn S
180 :S: Sequence number " nnnn S
181 :D: Date delta created " :Dy:/:Dm:/:Dd: S
182 :Dy: Year delta created " nn S
183 :Dm: Month delta created " nn S
184 :Dd: Day delta created " nn S
185 :T: Time delta created " :Th:::Tm:::Ts: S
186 :Th: Hour delta created " nn S
187 :Tm: Minutes delta created " nn S
188 :Ts: Seconds delta created " nn S
189 :P: Programmer who created Delta " logname S
190 :DS: Delta sequence number " nnnn S
191 :DP: Predecessor Delta sequence " nnnn S
192 number
193 :DI: Sequence number of deltas " :Dn:/:Dx:/:Dg: S
194 included, excluded, or ignored
195 :Dn: Deltas included (sequence #) " :DS: :DS: ... S
196 :Dx: Deltas excluded (sequence #) " :DS: :DS: ... S
197 :Dg: Deltas ignored (sequence #) " :DS: :DS: ... S
198 :MR: MR numbers for delta " text M
199 :C: Comments for delta " text M
200 :UN: User names User Names text M
201 :FL: Flag list Flags text M
202 :Y: Module type flag " text S
203
204 :MF: MR validation flag " yes or no S
205 :MP: MR validation program name " text S
206 :KF: Keyword error, warning flag " yes or no S
207 :KV: Keyword validation string " text S
208 :BF: Branch flag " yes or no S
209 :J: Joint edit flag " yes or no S
210 :LK: Locked releases " :R: ... S
211 :Q: User-defined keyword " text S
212 :M: Module name " text S
213 :FB: Floor boundary " :R: S
214 :CB: Ceiling boundary " :R: S
215 :Ds: Default SID " :I: S
216 :ND: Null delta flag " yes or no S
217 :FD: File descriptive text Comments text M
218 :BD: Body Body text M
219 :GB: Gotten body " text M
220 :W: A form of what string N/A :Z::M:\t:I: S
221 :A: A form of what string N/A :Z::Y: :M: :I::Z: S
222 :Z: what string delimiter N/A @(#) S
223 :F: SCCS filename N/A text S
224 :PN: SCCS file pathname N/A text S
225
226 * :Dt:= :DT: :I: :D: :T: :P: :DS: :DP:
227
228 ** :R:.:L:.:B:.:S: if the delta is a branch delta ( :BF:== yes)
229 :R:.:L: if the delta is not a branch delta ( :BF:== no)
230
231 *** The line statistics are capped at 99999. For example, if 100000
232 lines were unchanged in a certain revision, :Lu: shall produce
233 the value 99999.
234
235
237 The standard error shall be used only for diagnostic messages.
238
240 None.
241
243 None.
244
246 The following exit values shall be returned:
247
248 0 Successful completion.
249
250 >0 An error occurred.
251
252
254 Default.
255
256 The following sections are informative.
257
259 None.
260
262 1. The following example:
263
264
265 prs -d "User Names for :F: are:\n:UN:" s.file
266
267 might write to standard output:
268
269
270 User Names for s.file are:
271 xyz
272 131
273 abc
274
275 2. The following example:
276
277
278 prs -d "Delta for pgm :M:: :I: - :D: By :P:" -r s.file
279
280 might write to standard output:
281
282
283 Delta for pgm main.c: 3.7 - 77/12/01 By cas
284
285 3. As a special case:
286
287
288 prs s.file
289
290 might write to standard output:
291
292
293 s.file:
294 <blank line>
295 D 1.1 77/12/01 00:00:00 cas 1 000000/00000/00000
296 MRs:
297 bl78-12345
298 bl79-54321
299 COMMENTS:
300 this is the comment line for s.file initial delta
301 <blank line>
302
303 for each delta table entry of the D type. The only option allowed to be
304 used with this special case is the -a option.
305
307 None.
308
310 None.
311
313 admin, delta, get, what
314
316 Portions of this text are reprinted and reproduced in electronic form
317 from IEEE Std 1003.1, 2003 Edition, Standard for Information Technology
318 -- Portable Operating System Interface (POSIX), The Open Group Base
319 Specifications Issue 6, Copyright (C) 2001-2003 by the Institute of
320 Electrical and Electronics Engineers, Inc and The Open Group. In the
321 event of any discrepancy between this version and the original IEEE and
322 The Open Group Standard, the original IEEE and The Open Group Standard
323 is the referee document. The original Standard can be obtained online
324 at http://www.opengroup.org/unix/online.html .
325
326
327
328IEEE/The Open Group 2003 PRS(1P)