{
    "mode": "man",
    "parameter": "pr",
    "section": "1",
    "url": "https://www.chedong.com/phpMan.php/man/pr/1/json",
    "generated": "2026-05-30T04:01:29Z",
    "synopsis": "pr [OPTION]... [FILE]...",
    "sections": {
        "NAME": {
            "content": "pr - convert text files for printing\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "pr [OPTION]... [FILE]...\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "Paginate or columnate FILE(s) for printing.\n\nWith no FILE, or when FILE is -, read standard input.\n\nMandatory arguments to long options are mandatory for short options too.\n\n+FIRSTPAGE[:LASTPAGE], --pages=FIRSTPAGE[:LASTPAGE]\nbegin [stop] printing with page FIRST[LAST]PAGE\n",
            "subsections": [
                {
                    "name": "-COLUMN --columns",
                    "content": "output  COLUMN  columns  and  print columns down, unless -a is used. Balance number of\nlines in the columns on each page\n",
                    "long": "--columns"
                },
                {
                    "name": "-a --across",
                    "content": "print columns across rather than down, used together with -COLUMN\n",
                    "flag": "-a",
                    "long": "--across"
                },
                {
                    "name": "-c --show-control-chars",
                    "content": "use hat notation (^G) and octal backslash notation\n",
                    "flag": "-c",
                    "long": "--show-control-chars"
                },
                {
                    "name": "-d --double-space",
                    "content": "double space the output\n",
                    "flag": "-d",
                    "long": "--double-space"
                },
                {
                    "name": "-D --date-format",
                    "content": "use FORMAT for the header date\n",
                    "flag": "-D",
                    "long": "--date-format"
                },
                {
                    "name": "-e[CHAR[WIDTH]] --expand-tabs",
                    "content": "expand input CHARs (TABs) to tab WIDTH (8)\n",
                    "long": "--expand-tabs"
                },
                {
                    "name": "-F -f --form-feed",
                    "content": "use form feeds instead of newlines to separate pages (by a 3-line page header with  -F\nor a 5-line header and trailer without -F)\n",
                    "flag": "-f",
                    "long": "--form-feed"
                },
                {
                    "name": "-h --header",
                    "content": "use  a  centered HEADER instead of filename in page header, -h \"\" prints a blank line,\ndon't use -h\"\"\n",
                    "flag": "-h",
                    "long": "--header"
                },
                {
                    "name": "-i[CHAR[WIDTH]] --output-tabs",
                    "content": "replace spaces with CHARs (TABs) to tab WIDTH (8)\n",
                    "long": "--output-tabs"
                },
                {
                    "name": "-J --join-lines",
                    "content": "merge  full  lines,   turns   off   -W   line   truncation,   no   column   alignment,\n--sep-string[=STRING] sets separators\n",
                    "flag": "-J",
                    "long": "--join-lines"
                },
                {
                    "name": "-l --length",
                    "content": "set the page length to PAGELENGTH (66) lines (default number of lines of text 56, and\nwith -F 63).  implies -t if PAGELENGTH <= 10\n",
                    "flag": "-l",
                    "long": "--length"
                },
                {
                    "name": "-m --merge",
                    "content": "print all files in parallel, one in each column, truncate lines,  but  join  lines  of\nfull length with -J\n",
                    "flag": "-m",
                    "long": "--merge"
                },
                {
                    "name": "-n[SEP[DIGITS]] --number-lines",
                    "content": "number  lines, use DIGITS (5) digits, then SEP (TAB), default counting starts with 1st\nline of input file\n",
                    "long": "--number-lines"
                },
                {
                    "name": "-N --first-line-number",
                    "content": "start counting with NUMBER at 1st line of first page printed (see +FIRSTPAGE)\n",
                    "flag": "-N",
                    "long": "--first-line-number"
                },
                {
                    "name": "-o --indent",
                    "content": "offset each line with MARGIN (zero) spaces, do not affect -w or  -W,  MARGIN  will  be\nadded to PAGEWIDTH\n",
                    "flag": "-o",
                    "long": "--indent"
                },
                {
                    "name": "-r --no-file-warnings",
                    "content": "omit warning when a file cannot be opened\n",
                    "flag": "-r",
                    "long": "--no-file-warnings"
                },
                {
                    "name": "-s[CHAR] --separator",
                    "content": "separate  columns by a single character, default for CHAR is the <TAB> character with‐\nout -w and 'no char' with -w.  -s[CHAR] turns off line truncation of all 3 column  op‐\ntions (-COLUMN|-a -COLUMN|-m) except -w is set\n",
                    "long": "--separator"
                },
                {
                    "name": "-S[STRING] --sep-string",
                    "content": "separate  columns  by  STRING, without -S: Default separator <TAB> with -J and <space>\notherwise (same as -S\" \"), no effect on column options\n",
                    "long": "--sep-string"
                },
                {
                    "name": "-t --omit-header",
                    "content": "omit page headers and trailers; implied if PAGELENGTH <= 10\n",
                    "flag": "-t",
                    "long": "--omit-header"
                },
                {
                    "name": "-T --omit-pagination",
                    "content": "omit page headers and trailers, eliminate any pagination by form feeds  set  in  input\nfiles\n",
                    "flag": "-T",
                    "long": "--omit-pagination"
                },
                {
                    "name": "-v --show-nonprinting",
                    "content": "use octal backslash notation\n",
                    "flag": "-v",
                    "long": "--show-nonprinting"
                },
                {
                    "name": "-w --width",
                    "content": "set  page  width  to  PAGEWIDTH (72) characters for multiple text-column output only,\n-s[char] turns off (72)\n",
                    "flag": "-w",
                    "long": "--width"
                },
                {
                    "name": "-W --page-width",
                    "content": "set page width to PAGEWIDTH (72) characters always, truncate lines, except -J  option\nis set, no interference with -S or -s\n\n--help display this help and exit\n",
                    "flag": "-W",
                    "long": "--page-width"
                },
                {
                    "name": "--version",
                    "content": "output version information and exit\n",
                    "long": "--version"
                }
            ]
        },
        "AUTHOR": {
            "content": "Written by Pete TerMaat and Roland Huebner.\n",
            "subsections": []
        },
        "REPORTING BUGS": {
            "content": "GNU coreutils online help: <https://www.gnu.org/software/coreutils/>\nReport any translation bugs to <https://translationproject.org/team/>\n",
            "subsections": []
        },
        "COPYRIGHT": {
            "content": "Copyright  ©  2020 Free Software Foundation, Inc.  License GPLv3+: GNU GPL version 3 or later\n<https://gnu.org/licenses/gpl.html>.\nThis is free software: you are free to change and redistribute it.  There is NO WARRANTY,  to\nthe extent permitted by law.\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "Full documentation <https://www.gnu.org/software/coreutils/pr>\nor available locally via: info '(coreutils) pr invocation'\n\n\n\nGNU coreutils 8.32                          January 2026                                       PR(1)",
            "subsections": []
        }
    },
    "summary": "pr - convert text files for printing",
    "flags": [
        {
            "flag": "",
            "long": "--columns",
            "arg": null,
            "description": "output COLUMN columns and print columns down, unless -a is used. Balance number of lines in the columns on each page"
        },
        {
            "flag": "-a",
            "long": "--across",
            "arg": null,
            "description": "print columns across rather than down, used together with -COLUMN"
        },
        {
            "flag": "-c",
            "long": "--show-control-chars",
            "arg": null,
            "description": "use hat notation (^G) and octal backslash notation"
        },
        {
            "flag": "-d",
            "long": "--double-space",
            "arg": null,
            "description": "double space the output"
        },
        {
            "flag": "-D",
            "long": "--date-format",
            "arg": null,
            "description": "use FORMAT for the header date"
        },
        {
            "flag": "",
            "long": "--expand-tabs",
            "arg": null,
            "description": "expand input CHARs (TABs) to tab WIDTH (8)"
        },
        {
            "flag": "-f",
            "long": "--form-feed",
            "arg": null,
            "description": "use form feeds instead of newlines to separate pages (by a 3-line page header with -F or a 5-line header and trailer without -F)"
        },
        {
            "flag": "-h",
            "long": "--header",
            "arg": null,
            "description": "use a centered HEADER instead of filename in page header, -h \"\" prints a blank line, don't use -h\"\""
        },
        {
            "flag": "",
            "long": "--output-tabs",
            "arg": null,
            "description": "replace spaces with CHARs (TABs) to tab WIDTH (8)"
        },
        {
            "flag": "-J",
            "long": "--join-lines",
            "arg": null,
            "description": "merge full lines, turns off -W line truncation, no column alignment, --sep-string[=STRING] sets separators"
        },
        {
            "flag": "-l",
            "long": "--length",
            "arg": null,
            "description": "set the page length to PAGELENGTH (66) lines (default number of lines of text 56, and with -F 63). implies -t if PAGELENGTH <= 10"
        },
        {
            "flag": "-m",
            "long": "--merge",
            "arg": null,
            "description": "print all files in parallel, one in each column, truncate lines, but join lines of full length with -J"
        },
        {
            "flag": "",
            "long": "--number-lines",
            "arg": null,
            "description": "number lines, use DIGITS (5) digits, then SEP (TAB), default counting starts with 1st line of input file"
        },
        {
            "flag": "-N",
            "long": "--first-line-number",
            "arg": null,
            "description": "start counting with NUMBER at 1st line of first page printed (see +FIRSTPAGE)"
        },
        {
            "flag": "-o",
            "long": "--indent",
            "arg": null,
            "description": "offset each line with MARGIN (zero) spaces, do not affect -w or -W, MARGIN will be added to PAGEWIDTH"
        },
        {
            "flag": "-r",
            "long": "--no-file-warnings",
            "arg": null,
            "description": "omit warning when a file cannot be opened"
        },
        {
            "flag": "",
            "long": "--separator",
            "arg": null,
            "description": "separate columns by a single character, default for CHAR is the <TAB> character with‐ out -w and 'no char' with -w. -s[CHAR] turns off line truncation of all 3 column op‐ tions (-COLUMN|-a -COLUMN|-m) except -w is set"
        },
        {
            "flag": "",
            "long": "--sep-string",
            "arg": null,
            "description": "separate columns by STRING, without -S: Default separator <TAB> with -J and <space> otherwise (same as -S\" \"), no effect on column options"
        },
        {
            "flag": "-t",
            "long": "--omit-header",
            "arg": null,
            "description": "omit page headers and trailers; implied if PAGELENGTH <= 10"
        },
        {
            "flag": "-T",
            "long": "--omit-pagination",
            "arg": null,
            "description": "omit page headers and trailers, eliminate any pagination by form feeds set in input files"
        },
        {
            "flag": "-v",
            "long": "--show-nonprinting",
            "arg": null,
            "description": "use octal backslash notation"
        },
        {
            "flag": "-w",
            "long": "--width",
            "arg": null,
            "description": "set page width to PAGEWIDTH (72) characters for multiple text-column output only, -s[char] turns off (72)"
        },
        {
            "flag": "-W",
            "long": "--page-width",
            "arg": null,
            "description": "set page width to PAGEWIDTH (72) characters always, truncate lines, except -J option is set, no interference with -S or -s --help display this help and exit"
        },
        {
            "flag": "",
            "long": "--version",
            "arg": null,
            "description": "output version information and exit"
        }
    ],
    "examples": [],
    "see_also": []
}