From owner-freebsd-questions Thu May 27 16:39:34 1999 Delivered-To: freebsd-questions@freebsd.org Received: from scientia.demon.co.uk (scientia.demon.co.uk [212.228.14.13]) by hub.freebsd.org (Postfix) with ESMTP id 8899D15093 for ; Thu, 27 May 1999 16:39:27 -0700 (PDT) (envelope-from ben@scientia.demon.co.uk) Received: from rainbow5.scientia.demon.co.uk ([192.168.1.2] ident=exim) by scientia.demon.co.uk with esmtp (Exim 3.00 #1) id 10n8H1-00072N-00; Thu, 27 May 1999 23:05:11 +0100 (envelope-from ben@rainbow5.scientia.demon.co.uk) Received: from rainbow5.scientia.demon.co.uk (ident=ben) by rainbow5.scientia.demon.co.uk with local (Exim 3.00 #1) id 10n8H3-0000fv-00; Thu, 27 May 1999 23:05:13 +0100 (envelope-from ben@rainbow5.scientia.demon.co.uk) Date: Thu, 27 May 1999 23:05:13 +0100 From: Ben Smithurst To: Adam Breaux Cc: freebsd-questions@FreeBSD.ORG Subject: Re: Shell script Message-ID: <19990527230513.C2501@rainbow5.scientia.demon.co.uk> References: <013101bea87d$e26ee790$1e01a8c0@altronics.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.95.4i In-Reply-To: <013101bea87d$e26ee790$1e01a8c0@altronics.com> Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Adam Breaux wrote: > I need a shell script to remove page-breaks from a document before > printing...can someone help, I'm new to this *nix thing.... If the page breaks are just ^L, try: $ tr -d '^L' < infile.txt > outfile.txt or, to send it straight to the printer, $ tr -d '^L' < infile.txt | lp (the ^L is typed by doing ctrl+V then ctrl+L). If you need anything more complex, look at sed, awk or perl. -- Ben Smithurst ben@scientia.demon.co.uk To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message