1<!DOCTYPE HTML> 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> 13<b>lpr</b> 14[ 15<b>-E</b> 16] [ 17<b>-H </b><i>server</i>[<b>:</b><i>port</i>] 18] [ 19<b>-U</b> 20<i>username</i> 21] [ 22<b>-P </b><i>destination</i>[<b>/</b><i>instance</i>] 23] [ 24<b>-#</b> 25<i>num-copies</i> 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> 48<i>title</i> 49] [ 50<i>file(s)</i> 51] 52<h2 class="title"><a name="DESCRIPTION">Description</a></h2> 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 59<a href="man-lpoptions.html?TOPIC=Man+Pages"><b>lpoptions</b>(1)</a> 60command is used, followed by the default set using the 61<a href="man-lpadmin.html?TOPIC=Man+Pages"><b>lpadmin</b>(8)</a> 62command. 63<h2 class="title"><a name="OPTIONS">Options</a></h2> 64The following options are recognized by <i>lpr</i>: 65<dl class="man"> 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. 89<dt><b>-p</b> 90<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. 91This option is equivalent to <i>-o prettyprint</i> and is only useful when printing text files. 92<dt><b>-q</b> 93<dd style="margin-left: 5.0em">Hold job for printing. 94<dt><b>-r</b> 95<dd style="margin-left: 5.0em">Specifies that the named print files should be deleted after submitting them. 96</dl> 97<h2 class="title"><a name="NOTES">Notes</a></h2> 98The <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. 99<h2 class="title"><a name="EXAMPLES">Examples</a></h2> 100Print two copies of a document to the default printer: 101<pre class="man"> 102 103 lpr -# 2 filename 104 105</pre> 106Print a double-sided legal document to a printer called "foo": 107<pre class="man"> 108 109 lpr -P foo -o media=legal -o sides=two-sided-long-edge filename 110 111</pre> 112Print a presentation document 2-up to a printer called "foo": 113<pre class="man"> 114 115 lpr -P foo -o number-up=2 filename 116</pre> 117<h2 class="title"><a name="SEE_ALSO">See Also</a></h2> 118<a href="man-cancel.html?TOPIC=Man+Pages"><b>cancel</b>(1),</a> 119<a href="man-lp.html?TOPIC=Man+Pages"><b>lp</b>(1),</a> 120<a href="man-lpadmin.html?TOPIC=Man+Pages"><b>lpadmin</b>(8),</a> 121<a href="man-lpoptions.html?TOPIC=Man+Pages"><b>lpoptions</b>(1),</a> 122<a href="man-lpq.html?TOPIC=Man+Pages"><b>lpq</b>(1),</a> 123<a href="man-lprm.html?TOPIC=Man+Pages"><b>lprm</b>(1),</a> 124<a href="man-lpstat.html?TOPIC=Man+Pages"><b>lpstat</b>(1),</a> 125CUPS Online Help (<a href="http://localhost:631/help">http://localhost:631/help</a>) 126<h2 class="title"><a name="COPYRIGHT">Copyright</a></h2> 127Copyright © 2007-2014 by Apple Inc. 128 129</body> 130</html> 131