Subject: Re: GhostScript for Lazy People
To: Peter Seebach <seebs@plethora.net>
From: David Brownlee <abs@netbsd.org>
List: current-users
Date: 09/21/2000 21:26:47
This message is in MIME format. The first part should be readable text,
while the remaining parts are likely unreadable without MIME-aware tools.
Send mail to mime@docserver.cac.washington.edu for more info.
--0-1927852427-969568007=:272
Content-Type: TEXT/PLAIN; charset=US-ASCII
This might be prove of some use - I wrote it to allow printing
text, postscript or appropriate native binary printer gibberish to
random printers hooked up to either our NetBSD server or Windows
boxes around the office.
The non smb usage may need to be tweaked slightly - let me know...
Maybe this should be in pkgsrc? :)
David/absolute
-- www.netbsd.org: A pmap for every occasion --
On Thu, 21 Sep 2000, Peter Seebach wrote:
> Okay, I can use GS to render PostScript. I can send the output to a printer.
> Is there, somewhere out there, an existing script clever enough to just DWIM
> when output is sent to it? If so, does anyone have a config file for an Epson
> Stylus Color 600?
>
> Normally I'd just do it by hand, but this is for MomBSD, and I want it to
> be user-friendly.
>
> -s
>
--0-1927852427-969568007=:272
Content-Type: TEXT/PLAIN; charset=US-ASCII; name=if-psprint
Content-Transfer-Encoding: BASE64
Content-ID: <Pine.NEB.4.21.0009212126470.272@odysseus.mono.org>
Content-Description:
Content-Disposition: attachment; filename=if-psprint
IyEvdXNyL3BrZy9iaW4vcGVybCAtdw0KIyAkSWQkDQojIA0KIyAoYykgMjAw
MCBEYXZpZCBCcm93bmxlZSA8YWJzQG5ldGJzZC5vcmc+LiAgUGxhY2VkIGlu
IHRoZSBwdWJsaWMgZG9tYWluLA0KIyAgICAgKHdoaWNoIG1lYW5zIHNvbWVv
bmUgaXMgYm91bmQgdG8gc2xhcCBhIEdQTCBvbiBhIGNvcHkpLg0KIw0KIyBQ
cmludCB0ZXh0LCBwb3N0c2NyaXB0LCBvciBuYXRpdmUgcHJpbnRlciBsYW5n
dWFnZSB0byBhcmJpdHJhcnkgcHJpbnRlciwNCiMgZGVzaWduZWQgYXMgYSBx
dWljayBmb3IgZm9yIHRoZSByYW5kb20gcHJpbnR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