pr.1
来自「<B>Digital的Unix操作系统VAX 4.2源码</B>」· 1 代码 · 共 182 行
1
182 行
.TH pr 1.SH Namepr \- print files.SH Syntax.B pr[ \fIoptions\fR ][ \fIfiles\fR ].SH Description.NXR "print command"The.PN prcommand prints the named files on the standard output.If.I fileis designated by a minus sign (\-),or if no files are specified the.PN prcommand assumes standard input.By default, the listing is separated into pages,each headed by the page number, a date and time, andthe name of the file..PPBy default, columns are of equal width, separatedby at least one space. Lines that do not fit aretruncated. However, if the.B \-soption is used, lines are not truncatedand columns are separated by the separation character..PPIf the standard output is associated witha terminal, error messages are withhelduntil.PN prhas finished printing..SH OptionsThe following \fIoptions\fP can be used singly or in combination:.IP \fB\-a\fR 8Prints multi-column output across the page..IP \fB\-b\fR Prints blank headers..IP \fB\-d\fR Double-spaces the output..IP "\fB\-e\fIck\fR" Expands.I inputtabs to character positions\fIk\fP+1, 2*\fIk\fP+1, 3*\fIk\fP+1,... \fIn\fR*\fIk\fP+1.If.I kis 0 or is omitted, tabs are setat every eighth position.Tab characters in the input are expandedinto the appropriate number of spaces. The defaultfor .I c(any non-digit character)is the tab character; therefore, if.I cis given, it is treated as the input tab character..IP \fB\-f\fR Uses form-feed character for new pages.The default is to use a sequence of line-feeds.The \fB-f\fR option causes the.PN prcommand to pause before beginning the first page ifthe standard output is associated with a terminal..IP \fB\-h\fR Uses the next argument as the header to be printedinstead of the file name..IP "\fB\-i\fIck\fR" Replaces white space in .I outputby inserting tabsto character positions\fIk\fP+1, 2*\fIk\fP+1, 3*\fIk\fP+1,...\fIn\fR*\fIk\fP+1.If.I kis 0 or is omitted, tabs are setat every eighth position. The defaultfor .I c(any non-digit character)is the tab character; therefore, if.I cis given, it is treated as the input tab character..IP +\fIk\fR Begins printing with page.I k(default is 1)..IP \-\fIk\fR Produces.IR k \-columnoutput (default is 1).The .B \-eand.B \-ioptions are assumed for multi-column output..IP "\fB\-l\fIk\fR" Sets the length of a page to.I klines. The default is 66 lines..IP \fB\-m\fR Merges and prints all files simultaneously,one per column (overrides the \-\fIk\fP,and.B \-aoptions)..IP "\fB\-n\fIck\fR" Numbers lines. The default for .B kis 20.The number occupies the first \fIk\fP+1character positions of each column of normal outputor each line of.B \-moutput.If.I c,which is any non-digit character is given,it is appended to the line number to separateit from whatever follows. The default for.I cis a tab..IP "\fB\-o\fIk" Offsets each line by.I kcharacter positions (default is 0).The number of character positionsper line is the sum of the width and offset..IP \fB\-p\fR Pauses before beginning each page if theoutput is directed to a terminal. The.PN prcommand rings the bell at the terminal andawaits a carriage return..IP \fB\-r\fR Suppresses diagnostic reports on failure to open files..IP "\fB\-s\fIc\fR" Separates columns by the single character.I cinstead of by the appropriate numberof spaces (default for.I cis a tab)..IP \fB\-t\fR Suppresses the five-line identifyingheader and the five-line trailer normallysupplied for each page.The \fB-t\fR option causes the.PN prcommand to quit printing after the last line of each filewithout spacing to the end of the page..IP "\fB\-w\fIk\fR" Sets the width of a line to.I kcharacter positions. Thedefault is 72 for equal-width multi-columnoutput; otherwise there is no limit..SH ExamplesPrint.I file1and.I file2as a double-spaced, three-column listingwith the heading: file list..EXpr \|\-3dh \|"file \|list" \|file1 \|file2.EEWrite.I file1on.I file2,expanding tabs to columns 10, 19, 28, 37,...:.EXpr \-e9 \-t <file1>file2.EE.SH Files/dev/tty\(** to suspend messages.SH See Alsocat(1)
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?