Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

The lpr man page says a destination printer can be specified with the -P flag.

-P destination[/instance]
    Prints files to the named printer.

I have 'added' various printers on local Samba shares using the GUI in Ubuntu/Gnome. How can I get a list of these available printers in the format that the -P flag expects (preferably from a bash shell)?

share|improve this question

1 Answer 1

up vote 19 down vote accepted
$ lpstat -p -d

From the CUPS manual.

share|improve this answer
1  
Thank you! I've just found that lpq works too. –  Ian Mackinnon Aug 18 '10 at 16:56

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.