From owner-freebsd-questions@FreeBSD.ORG Tue May 6 17:08:13 2003 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E76AC37B404 for ; Tue, 6 May 2003 17:08:13 -0700 (PDT) Received: from wonkity.com (wonkity.com [65.173.111.5]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1D44B43F93 for ; Tue, 6 May 2003 17:08:11 -0700 (PDT) (envelope-from wblock@wonkity.com) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.12.9/8.12.9) with ESMTP id h470873p000273; Tue, 6 May 2003 18:08:07 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.12.9/8.12.9/Submit) with ESMTP id h47087X3000270; Tue, 6 May 2003 18:08:07 -0600 (MDT) Date: Tue, 6 May 2003 18:08:07 -0600 (MDT) From: Warren Block To: Len Zettel In-Reply-To: <3EB828A1.9BCAED92@acm.org> Message-ID: <20030506180317.C225@wonkity.com> References: <3EB828A1.9BCAED92@acm.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: freebsd-questions@freebsd.org Subject: Re: Designating the default printer X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 May 2003 00:08:14 -0000 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