Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 3 Apr 2003 21:23:28 -0700 (MST)
From:      Warren Block <wblock@wonkity.com>
To:        David Banning <david@skytracker.ca>
Cc:        questions@freebsd.org
Subject:   Re: customizing printcap to email file
Message-ID:  <20030403211401.A83838@wonkity.com>
In-Reply-To: <20030403153320.A43931@skytrackercanada.com>
References:  <20030403153320.A43931@skytrackercanada.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 3 Apr 2003, David Banning wrote:

> what I would like to do is have windows boxes print to a unix
> printer filter which would convert the file into pdf format
> and put the file into a directory where it could be emailed
> out.

> Anyone tried this? First off, I tried modifying the printcap if=
> entry to take the file and save it as a file. That was a no go - I
> just got an error. Now I am thinking about just stopping the printer,
> which would spool the files in the spool directory. I still need
> to initiate execution of a program to grab those files and convert
> them.

Setting it up as an input filter is the better way, I think.  You just
need to create a filter (script or program) and point the if= parameter
to that.  It's easier to debug filters before they're being called by
lpd.

Set up a script that takes STDIN, processes it into PDF, then mails it.
That's your filter.  After it's been tested, put it someplace known
(filters often are placed in /usr/local/libexec) and give the whole path
in the if= entry.

-Warren Block * Rapid City, South Dakota USA



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030403211401.A83838>