From owner-freebsd-questions@FreeBSD.ORG Fri Nov 28 12:37:32 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 64D6516A4CE for ; Fri, 28 Nov 2003 12:37:32 -0800 (PST) Received: from billschoolcraft.com (adsl-63-204-157-14.dsl.snfc21.pacbell.net [63.204.157.14]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6BF0043FBD for ; Fri, 28 Nov 2003 12:37:31 -0800 (PST) (envelope-from bill@wiliweld.com) Received: from localhost (localhost [127.0.0.1]) by billschoolcraft.com (Postfix) with ESMTP id 8EAB9575F for ; Fri, 28 Nov 2003 13:40:47 +0000 (GMT) Date: Fri, 28 Nov 2003 13:40:47 +0000 (GMT) From: Bill Schoolcraft X-X-Sender: bill@bsd.billschoolcraft.com To: freebsd-questions@FreeBSD.ORG In-Reply-To: <200311282018.57848.ajacoutot@lphp.org> Message-ID: <20031128132502.K2753@bsd.billschoolcraft.com> References: <200311282018.57848.ajacoutot@lphp.org> System-ID: [en] (I; FreeBSD 4.8-RELEASE #0 x86) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Subject: Re: how to print a man page 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: Fri, 28 Nov 2003 20:37:32 -0000 At Fri, 28 Nov 2003 it looks like Antoine Jacoutot composed: > On Friday 28 November 2003 20:10, Ian Todd wrote: > > I have installed a local printer on /dev/lp0. I want to > > print a man page how do i do that? Will it also fit onto > > the page? i dont need to setup the size of my page?Thanks. > > $ groff -Tps -man /path/to/man/page/man.1 | lpr -P PS-Printer > Cool, never saw that method, I've used the following but of course I end up with an extra file here unless I throw in an rm command at the end for the file in question. man yourchoice | col -b > manpage.txt ; lpr yourchoice.txt Or the following script works, you could call it "manp.sh" --------------------snip-------------------- #!/bin/sh # echo echo "Formatting and printing the manpage called $1 " echo man $1 | col -b > $1.txt ; lpr $1.txt ; rm -f $1.txt echo "Your manpage has been sent to the printer " echo --------------------snip--------------------