Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 6 May 2003 18:08:07 -0600 (MDT)
From:      Warren Block <wblock@wonkity.com>
To:        Len Zettel <zettel@acm.org>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Designating the default printer
Message-ID:  <20030506180317.C225@wonkity.com>
In-Reply-To: <3EB828A1.9BCAED92@acm.org>
References:  <3EB828A1.9BCAED92@acm.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 6 May 2003, Len Zettel wrote:

> This is my /etc/printcap file.
>
> Laserjet|hp|Hewlett Packard Laserjet 1100:\
> 	:sh:sd=/var/spool/lpd/Laserjet:\
> 	:lp=/dev/lpt0:\
> 	:if=/usr/local/libexec/if-simple:

> Following Unix Power Tools 43.04, p 790, entering
> PRINTER=Laserjet ; export PRINTER
> from a console lets me do
> lpr foo
> file foo is printed as above.
>
> Question: What do I put where to specify Laserjet as
> the default printer as part of the boot sequence?

Normally, the default printer has a name of "lp", so you could add that
to your /etc/printcap entry by changing the first line to look like
this:

lp|Laserjet|hp|Hewlett Packard Laserjet 1100:\

But if you want to change the PRINTER variable, you'd do that in the
startup script for your shell.  The details vary depending on the shell
you're using; from the variable-setting line you showed, it looks like
you're using BASH.  So you'd put it in one of the BASH shell startup
scripts.  I don't know which one is most appropriate; I always used
.profile (back when I used BASH).

-Warren Block * Rapid City, South Dakota USA



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