print specific pages of a pdf from the command line?

Patton Echols p.echols at comcast.net
Sat May 29 08:09:21 UTC 2010


listofx wrote:
> see the help from cups:
> firefox file:///usr/share/cups/doc-root/help/options.html
>
> -------quote------------
> Selecting a Range of Pages
> The -o page-ranges=pages option selects a range of pages for printing:
>
> lp -o page-ranges=1 filename
> lp -o page-ranges=1-4 filename
> lp -o page-ranges=1-4,7,9-12 filename
> lpr -o page-ranges=1-4,7,9-12 filename
>   

Interesting. good to know. This is much more direct for OP's task.

If using pdf documents and needing even more flexibility than this,
pdftk is still an option because it can explicitly combine options and
do things like 2 pages from document A, odd pages from document B, three
pages from document C and then four more from document A and print in
that order. To be honest, I cannot imagine when I would need to do such
a thing!

-- PE




More information about the ubuntu-users mailing list