Monday, March 12, 2007

LPR to the rescue in Linux

I had been researching this metalink note: to accomodate one of our power user's wish of direct PDF printing on a HP printer.

I could not tame the "Cat" (command), after wasting a lot of time, it was LPR who helped me gain my lost confidence in Linux printing:

herez how:

follow doc 262657.1

use lpr instead of lp and the acrobat installation :

logic:

cat <> /usr/Acrobat4/bin/acroread -toPostScript -shrink lp -c -d <> -n

this above statement from the note is not fasible at times so, when things do not improve even after installing Adobe Acrobat reader. We need to turn back to linux commands such as :

pdftops - pdf to poscript
pdftotext - pdf to text
texttopdf - text to pdf etc. etc.

we can try to use these commands in the place of acroread,

now, if we look at linux printing commands closely, there is a command which uses these pdftops, pdftotext etc., implicitly which is LPR. so start using lpr in a simple way and we will get thru this, but the prerequsite is that pdfto* commands work properly on the Linux/unix OS.

so this takes us to the command :

lpr -P$PROFILES$.PRINTER -#$PROFILES$.CONC_COPIES -T"$PROFILES$.TITLE" $PROFILES$.FILENAME

this works perfectly.

This is an existing command line driver without initialization arguments

Browse through some working command drivers and determine which is best for you.

So LPR is the savior.