On 5/6/06, centos@911networks.com centos@911networks.com wrote:
How can I print, from the command line, a png file?
Presuming that you have cups installed in the normal fashion and a default printer, just
cat xxx.png | lpr
Enjoy.
-- Collins Richey If you fill your heart with regrets of yesterday and the worries of tomorrow, you have no today to be thankful for.
On Sat, 2006-05-06 at 10:23 -0600, Collins Richey wrote:
On 5/6/06, centos@911networks.com centos@911networks.com wrote:
How can I print, from the command line, a png file?
Presuming that you have cups installed in the normal fashion and a default printer, just
cat xxx.png | lpr
Try "lpr <filename>"
Avoids the process for a filter (cat) which is doing nothing for you.
<snip sigs>
HTH
On Sat, 6 May 2006, William L. Maltby wrote:
cat xxx.png | lpr
Try "lpr <filename>"
Avoids the process for a filter (cat) which is doing nothing for you.
While this is true in Centos, if one moves between *nix implementations, it is an unsafe habit to have (using lpr directly), as in early Unix implementations, lpr is occasionally set to _delete_ the file it has just completed printing.
-- Russ Herrold
On Sun, 2006-05-07 at 15:55 -0400, R P Herrold wrote:
On Sat, 6 May 2006, William L. Maltby wrote:
cat xxx.png | lpr
Try "lpr <filename>"
Avoids the process for a filter (cat) which is doing nothing for you.
While this is true in Centos, if one moves between *nix implementations, it is an unsafe habit to have (using lpr directly), as in early Unix implementations, lpr is occasionally set to _delete_ the file it has just completed printing.
I consider those broken. If there is doubt, a test or review of the docs should let one know. Anyway, no one cares about those "subtleties" anymore. I know I'm pissing in the wind when I bring up stuff like that.
-- Russ Herrold
<snip sig stuff>
On Sun, 2006-05-07 at 15:55 -0400, R P Herrold wrote:
On Sat, 6 May 2006, William L. Maltby wrote:
cat xxx.png | lpr
Try "lpr <filename>"
Avoids the process for a filter (cat) which is doing nothing for you.
While this is true in Centos, if one moves between *nix implementations, it is an unsafe habit to have (using lpr directly), as in early Unix implementations, lpr is occasionally set to _delete_ the file it has just completed printing.
Not to be anal, but then
lpr < filename
should be safe.
-- Russ Herrold
<snip sig stuff>
On Sat, 2006-05-06 at 10:23 -0600, Collins Richey wrote:
On 5/6/06, centos@911networks.com centos@911networks.com wrote:
How can I print, from the command line, a png file?
Presuming that you have cups installed in the normal fashion and a default printer, just
cat xxx.png | lpr
BTW, for *any* process like this taht does not handle a file name on a command line, if not fileter is needed (no concatenation, slicing, converting...) it is always more efficient to do an I/O redirection.
lpr <xxx.png
standard shell stuff. I propose we teach "The Right Way" (TM).
<snip sig>
HTH