foomatic-rip [-J<jobtitle>] foomatic-rip [-J<jobtitle>] [-Z<option>=<value>[, <option>=<value>[, ...]] (printcap :pdd=<ppdfile>)
foomatic-rip --ppd <ppdfile> [-J<jobtitle>] [-Z<option> [-J<jobtitle>] [-Z<option> =<value>[,<option>=<value> [, ...]]
It translates PostScript (and also other file formats) from standard input to the printer's native language (usually put to standard output).
foomatic-rip -P <printer> -o docs <file>
(<file> can be an arbitrary existing file, as .bashrc, will not be printed) to print a list of available options for the specified <printer>.
foomatic-rip will print from standard input unless a file to print is specified on the command line. If your printer PPD file is stored as /etc/foomatic/direct/<printer>.ppd or ~/.foomatic/direct/<printer>.ppd you can use it by simply specifying "-P <printer>".
Put a line
*FoomaticRIPPostPipe: "| <command>"
into the PPD file, right after *PPD-Adobe: "4.3", where <command> is a command into which you wnat to re-direct the output data. Due to the restictions of PPD files <, >, and " are not allowed in the <command>, replace them as follows:
Character Replacement ---------------------
This way you can print directly to your printer, use
*FoomaticRIPPostPipe: "| cat > /dev/lp0"
or
*FoomaticRIPPostPipe: "| cat > /dev/usb/lp0"
for local parallel or USB printers. To make normal users able to print this way add them to the group lp and make sure that the appropriate printer device file /dev/... is group-writable for the lp group.
for a TCP/Socket/JetDirect printer with the host name printer listening on port 9100 you need this:
*FoomaticRIPPostPipe: "| /usr/bin/nc -w 1 printer 9100"
Note the "-w 1" in the "nc" command line, it makes "nc" exiting immediately after the data is tranferred to the printer.
*FoomaticRIPPostPipe: "| rlpr -Plp@printserver"
directs your jobs to the LPD printer queue lp on the machine named printserver.
See also
See the documentation on the Linux Printing Web site: http://www.linuxprinting.org
The PPD files of the currently defined printers
Please send bug reports to foomatic-devel@linuxprinting.org.