Examples

From UW-Math Wiki
Revision as of 14:30, 29 June 2011 by Ynagel (talk | contribs)
Jump to navigation Jump to search

A sampler of lp commands

If you use command line to print, send only postscript or pdf files to the copier. The basic command is

        lp  file.pdf

By default, you will get duplexed (long-edge), grayscale prints if you print to the copiers. Some useful options are

Examples:

        lp -d P file.pdf  (send file to printer P - e.g. P=5)
        lp -o ColorModel=color file.pdf    (print in color)
        lp -o sides=two-sided-short-edge  file.pdf  (duplex along short edge instead of long)
        lp -o page-ranges=1  (print just page 1)
        lp -o page-ranges=1-4,7,9-12


You can combine these commands, for example:

        lp -o sides=two-sided-short-edge -o ColorModel=color file.pdf  (useful for printing tri-fold brochures)

lpoptions

Use the lpoptions command to save these options for later use. For example, you might want to do color printing to the printer on another floor, reserving the printer on your own floor for the normal grayscale prints. This command will ensure that anything you send to the 5th floor printer will be printed in color:

        lpoptions -d 5  ColorModel=color

your lpoptions commands are saved in the file ~/.cups/lpoptions. Typing lpoptions by itself will show you what your current printer setup is.