I need to make lpr print just the first page of my document, however it continues to print everything. Itried these commands:
lpr -P <myprinter> -o page-ranges=1 <myfile> lp -d <myprinter> -o page-ranges=1 <myfile> lp -d <myprinter> P 1 <myfile>
Appears it would be: lp -p 1
(plus whatever else you'll need to pass to lp to get it to print what you want to print).
It depends on the CUPS version. To the googlers of the future:
The probable reason behind your problem is that there are previous projects left in your queue. You can check this in the CUPS administration panel on http://localhost:631 . Go to the printer managing and delete all of the tasks there is yet in the printer queue.
And so, you won. Problem solved. Page-ranges work. We are happy. Good luck!