]> git.ipfire.org Git - thirdparty/cups.git/blame - doc/help/man-lpr.html
Greatly simplify the man page handling.
[thirdparty/cups.git] / doc / help / man-lpr.html
CommitLineData
c277f98c 1<!DOCTYPE HTML>
94436c5a
MS
2<html>
3<!-- SECTION: Man Pages -->
4<head>
5 <link rel="stylesheet" type="text/css" href="../cups-printable.css">
6 <title>lpr(1)</title>
7</head>
8<body>
9<h1 class="title">lpr(1)</h1>
10<h2 class="title"><a name="NAME">Name</a></h2>
11lpr - print files
12<h2 class="title"><a name="SYNOPSIS">Synopsis</a></h2>
c277f98c 13<b>lpr</b>
cfa19b58
MS
14[
15<b>-E</b>
16] [
17<b>-H </b><i>server</i>[<b>:</b><i>port</i>]
18] [
19<b>-U</b>
c277f98c 20<i>username</i>
cfa19b58
MS
21] [
22<b>-P </b><i>destination</i>[<b>/</b><i>instance</i>]
23] [
24<b>-#</b>
c277f98c 25<i>num-copies</i>
cfa19b58
MS
26[
27<b>-h</b>
28] [
29<b>-l</b>
30] [
31<b>-m</b>
32] [
33<b>-o </b><i>option</i>[<b>=</b><i>value</i>]
34] [
35<b>-p</b>
36] [
37<b>-q</b>
38] [
39<b>-r</b>
40] [
41<b>-C</b>
42<i>title</i>
43] [
44<b>-J</b>
45<i>title</i>
46] [
47<b>-T</b>
c277f98c
MS
48<i>title</i>
49] [
50<i>file(s)</i>
51]
94436c5a 52<h2 class="title"><a name="DESCRIPTION">Description</a></h2>
cfa19b58
MS
53<b>lpr</b> submits files for printing.
54Files named on the command line are sent to the named printer or the default destination if no destination is specified.
55If no files are listed on the command-line, <b>lpr</b> reads the print file from the standard input.
56<h3><a name="THE_DEFAULT_DESTINATION">The Default Destination</a></h3>
57CUPS provides many ways to set the default destination. The <b>LPDEST</b> and <b>PRINTER</b> environment variables are consulted first.
58If neither are set, the current default set using the
87030afb 59<b>lpoptions</b>(1)
cfa19b58 60command is used, followed by the default set using the
87030afb 61<b>lpadmin</b>(8)
cfa19b58 62command.
94436c5a
MS
63<h2 class="title"><a name="OPTIONS">Options</a></h2>
64The following options are recognized by <i>lpr</i>:
2909c66c 65<dl class="man">
cfa19b58
MS
66<dt><b>-E</b>
67<dd style="margin-left: 5.0em">Forces encryption when connecting to the server.
68<dt><b>-H </b><i>server</i>[<b>:</b><i>port</i>]
69<dd style="margin-left: 5.0em">Specifies an alternate server.
70<dt><b>-C "</b><i>name</i><b>"</b>
71<dd style="margin-left: 5.0em"><dt><b>-J "</b><i>name</i><b>"</b>
72<dd style="margin-left: 5.0em"><dt><b>-T "</b><i>name</i><b>"</b>
73<dd style="margin-left: 5.0em">Sets the job name/title.
74<dt><b>-P </b><i>destination</i>[<b>/</b><i>instance</i>]
75<dd style="margin-left: 5.0em">Prints files to the named printer.
76<dt><b>-U </b><i>username</i>
77<dd style="margin-left: 5.0em">Specifies an alternate username.
78<dt><b>-# </b><i>copies</i>
79<dd style="margin-left: 5.0em">Sets the number of copies to print.
80<dt><b>-h</b>
81<dd style="margin-left: 5.0em">Disables banner printing. This option is equivalent to <i>-o job-sheets=none</i>.
82<dt><b>-l</b>
83<dd style="margin-left: 5.0em">Specifies that the print file is already formatted for the destination and should be sent without filtering.
84This option is equivalent to <i>-o raw</i>.
85<dt><b>-m</b>
86<dd style="margin-left: 5.0em">Send an email on job completion.
87<dt><b>-o </b><i>option</i>[<b>=</b><i>value</i>]
88<dd style="margin-left: 5.0em">Sets a job option.
423e6ddb 89See "COMMON JOB OPTIONS" below.
cfa19b58
MS
90<dt><b>-p</b>
91<dd style="margin-left: 5.0em">Specifies that the print file should be formatted with a shaded header with the date, time, job name, and page number.
92This option is equivalent to <i>-o prettyprint</i> and is only useful when printing text files.
93<dt><b>-q</b>
94<dd style="margin-left: 5.0em">Hold job for printing.
95<dt><b>-r</b>
96<dd style="margin-left: 5.0em">Specifies that the named print files should be deleted after submitting them.
2909c66c 97</dl>
423e6ddb
MS
98<h3><a name="COMMON_JOB_OPTIONS">Common Job Options</a></h3>
99Aside from the printer-specific options reported by the
87030afb 100<b>lpoptions</b>(1)
423e6ddb
MS
101command, the following generic options are available:
102<dl class="man">
423e6ddb
MS
103<dt><b>-o job-sheets=</b><i>name</i>
104<dd style="margin-left: 5.0em">Prints a cover page (banner) with the document.
105The "name" can be "classified", "confidential", "secret", "standard", "topsecret", or "unclassified".
423e6ddb
MS
106<dt><b>-o media=</b><i>size</i>
107<dd style="margin-left: 5.0em">Sets the page size to <i>size</i>. Most printers support at least the size names "a4", "letter", and "legal".
423e6ddb
MS
108<dt><b>-o number-up=</b>{<i>2|4|6|9|16</i>}
109<dd style="margin-left: 5.0em">Prints 2, 4, 6, 9, or 16 document (input) pages on each output page.
423e6ddb
MS
110<dt><b>-o orientation-requested=4</b>
111<dd style="margin-left: 5.0em">Prints the job in landscape (rotated 90 degrees counter-clockwise).
112<dt><b>-o orientation-requested=5</b>
113<dd style="margin-left: 5.0em">Prints the job in landscape (rotated 90 degrees clockwise).
114<dt><b>-o orientation-requested=6</b>
115<dd style="margin-left: 5.0em">Prints the job in reverse portrait (rotated 180 degrees).
51c22b86
MS
116<dt><b>-o print-quality=3</b>
117<dd style="margin-left: 5.0em"><dt><b>-o print-quality=4</b>
118<dd style="margin-left: 5.0em"><dt><b>-o print-quality=5</b>
119<dd style="margin-left: 5.0em">Specifies the output quality - draft (3), normal (4), or best (5).
423e6ddb
MS
120<dt><b>-o sides=one-sided</b>
121<dd style="margin-left: 5.0em">Prints on one side of the paper.
122<dt><b>-o sides=two-sided-long-edge</b>
123<dd style="margin-left: 5.0em">Prints on both sides of the paper for portrait output.
124<dt><b>-o sides=two-sided-short-edge</b>
125<dd style="margin-left: 5.0em">Prints on both sides of the paper for landscape output.
126</dl>
cfa19b58
MS
127<h2 class="title"><a name="NOTES">Notes</a></h2>
128The <i>-c</i>, <i>-d</i>, <i>-f</i>, <i>-g</i>, <i>-i</i>, <i>-n</i>, <i>-t</i>, <i>-v</i>, and <i>-w</i> options are not supported by CUPS and produce a warning message if used.
129<h2 class="title"><a name="EXAMPLES">Examples</a></h2>
130Print two copies of a document to the default printer:
131<pre class="man">
132
133 lpr -# 2 filename
134
135</pre>
136Print a double-sided legal document to a printer called "foo":
137<pre class="man">
138
139 lpr -P foo -o media=legal -o sides=two-sided-long-edge filename
140
141</pre>
142Print a presentation document 2-up to a printer called "foo":
143<pre class="man">
144
145 lpr -P foo -o number-up=2 filename
146</pre>
94436c5a 147<h2 class="title"><a name="SEE_ALSO">See Also</a></h2>
87030afb
MS
148<b>cancel</b>(1),
149<b>lp</b>(1),
150<b>lpadmin</b>(8),
151<b>lpoptions</b>(1),
152<b>lpq</b>(1),
153<b>lprm</b>(1),
154<b>lpstat</b>(1),
cfa19b58 155CUPS Online Help (<a href="http://localhost:631/help">http://localhost:631/help</a>)
94436c5a 156<h2 class="title"><a name="COPYRIGHT">Copyright</a></h2>
87030afb 157Copyright &copy; 2007-2019 by Apple Inc.
94436c5a
MS
158
159</body>
160</html>