PR(1)
β¨ PR(1) β the paginate-and-columnate manual, but make it cute β¨
okay bestie, welcome to PR(1), aka the General Commands Manual entry you're gonna actually read for once π This is the glow-up of the pr page, and no, I'm not skipping a single flag, so grab a snack π
πΈ NAME πΈ
pr β paginate or columnate FILE(s) for printing π
π¦ SYNOPSIS π¦
pr [OPTION]... [FILE]...
π DESCRIPTION π
paginate or columnate FILE(s) for printing. that's it, that's the whole vibe. it takes your files and makes them all neat and page-shaped so the printer doesn't get confused π
π OPTIONS π
so many flags. all of them iconic. none of them skipped. periodt β¨
--pages <FIRST_PAGE[:LAST_PAGE]>β begin and stop printing with page FIRST_PAGE[:LAST_PAGE]. like, start here, stop there, no extra pages bestie π«Ά-h,--header <STRING>β use the string header to replace the file name in the header line. your file gets a little name tag makeover π-D,--date-format <FORMAT>β usedate-style FORMAT for the header date. it's giving customizable time stamps β¨-d,--double-spaceβ produce output that is double spaced. an extra<newline>character is output following every<newline>found in the input. everything gets breathing room π¬οΈ-n,--number-lines [<[char][width]>]β provide width digit line numbering. the default for width, if not specified, is5. the number occupies the first width column positions of each text column or each line of-moutput. if char (any non-digit character) is given, it is appended to the line number to separate it from whatever follows. the default for char is a<tab>. line numbers longer than width columns are truncated. so they get numbered, and if they're too long they get cut, no cap π-N,--first-line-number <NUMBER>β start counting with NUMBER at 1st line of first page printed. not me starting at 1 like a rookie π-t,--omit-headerβ write neither the five-line identifying header nor the five-line trailer usually supplied for each page. quit writing after the last line of each file without spacing to the end of the page. bye bye headers, bye bye trailers, bye bye filler blank space π-T,--omit-paginationβ omit page headers and trailers, eliminate any pagination by form feeds set in input files. full chaos mode, no page breaks allowed π₯-l,--length <PAGE_LENGTH>β override the 66-line default (default number of lines of text56, and with-F63) and reset the page length to lines. if lines is not greater than the sum of both the header and trailer depths (in lines), theprutility shall suppress both the header and trailer, as if the-toption were in effect. so if your page is too smol for the header + trailer combo,prjust ghosts them entirely π-r,--no-file-warningsβ omit warning when a file cannot be opened. we're keeping it peaceful, no negativity in this group chat ποΈ-F,--form-feedβ use a<form-feed>for new pages, instead of the default behavior that uses a sequence of<newline>s. different page-break flavor, same slay β-w,--width <width>β set the width of the line to width column positions for multiple text-column output only. if the-woption is not specified and the-soption is not specified, the default width shall be72. if the-woption is not specified and the-soption is specified, the default width shall be512. okay so it only matters when you've got multiple columns, got it π-W,--page-width <width>β set page width to PAGE_WIDTH (72) characters always, truncate lines, except-Joption is set, no interference with-Sor-s. strict width behavior, lines get truncated,-Jis the one exception π―-a,--acrossβ modify the effect of the-column option so that the columns are filled across the page in a round-robin order (for example, when column is2, the first input line heads column 1, the second heads column 2, the third is the second line in column 1, and so on). it's giving board-game turn order, everyone gets a turn π²--columns <columns>β produce multi-column output that is arranged in column columns (the default shall be1) and is written down each column in the order in which the text is received from the input file. this option should not be used with-m. the options-eand-ishall be assumed for multiple text-column output. whether or not text columns are produced with identical vertical lengths is unspecified, but a text column shall never exceed the length of the page (see the-loption). when used with-t, use the minimum number of lines to write the output. β¨-s,--separator [<char>]β separate text columns by the single character char instead of by the appropriate number of<space>s (default for char is the<tab>character). one lil character between columns, so tidy π-S,--sep-string [<string>]β separate columns by STRING, without-S: default separator<TAB>with-Jand<space>otherwise (same as-S\" \"), no effect on column options. you want a string in between? bet π-m,--mergeβ merge files. standard output shall be formatted so theprutility writes one line from each file specified by a file operand, side by side into text columns of equal fixed widths, in terms of the number of column positions. implementations shall support merging of at least nine file operands. nine files side by side, that's the minimum, and it's iconic π-o,--indent <margin>β each line of output shall be preceded by offset<space>s. if the-ooption is not specified, the default offset shall be zero. the space taken is in addition to the output line width (see the-woption below). a little margin, a little room to breathe π§-J,--join-linesβ merge full lines, turns off-Wline truncation, no column alignment,--sep-string[=STRING]sets separators. π₯--helpβ print help information π-e,--expand-tabs <[CHAR][WIDTH]>β expand input CHARs (TABs) to tab WIDTH (8). tabs become spaces, the tab erasure is real π-V,--versionβ print version π[files] [default: -]β the files go here bestie, and if you don't give any, the default is-π«Ά
π EXTRA π
if no FILE(s) are given, or if FILE is -, read standard input. so stdin is always on the guest list π
when creating multicolumn output, columns will be of equal width. when using the '-s' option to separate columns, the default separator is a single tab character. when using the '-S' option to separate columns, the default separator is a single space character. equality, tabs, spaces β the whole lineup β¨
π« VERSION π«
v(uutils coreutils) 0.12.0
π EXAMPLES π
print multiple files with a default header and footer:
pr path/to/file1 path/to/file2 ...
print with a custom centered header:
pr [-h|--header] "header" path/to/file1 path/to/file2 ...
print with numbered lines and a custom date format:
pr [-n|--number-lines] [-D|--date-format] "format" path/to/file1 path/to/file2 ...
print all files together, one in each column, without a header or footer:
pr [-m|--merge] [-T|--omit-pagination] path/to/file1 path/to/file2 ...
print, beginning at page 2 up to page 5, with a given page length (including header and footer):
pr +2:5 [-l|--length] page_length path/to/file1 path/to/file2 ...
print with an offset for each line and a truncating custom page width:
pr [-o|--indent] offset [-W|--page_width] width path/to/file1 path/to/file2 ...
the examples are provided by the tldr-pages project <https://tldr.sh> under the CC BY 4.0 License. please note that, as uutils is a work in progress, some examples might fail. π (no shade, it's just still cooking π³)
and that's the whole page bestie!! slay, you now know pr better than 90% of people who use it πβ¨ this was PR(1) from the General Commands Manual, sourcing from uutils coreutils version 0.12.0, dated 2026-09-25 β mwah, go paginate something gorgeous, ily, bye ππ¦πΈ
π¦ where this page comes from
- ubuntu stonking: rust-coreutils 0.12.0-1ubuntu2 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms