From owner-freebsd-questions Mon Feb 15 16:57:50 1999 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id QAA04707 for freebsd-questions-outgoing; Mon, 15 Feb 1999 16:57:50 -0800 (PST) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from dan.emsphone.com (dan.emsphone.com [199.67.51.101]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id QAA04695 for ; Mon, 15 Feb 1999 16:57:46 -0800 (PST) (envelope-from dan@dan.emsphone.com) Received: (from dan@localhost) by dan.emsphone.com (8.9.1/8.9.1) id SAA21877; Mon, 15 Feb 1999 18:57:22 -0600 (CST) Date: Mon, 15 Feb 1999 18:57:22 -0600 From: Dan Nelson To: Sue Blake Cc: Greg Lehey , rick hamell , freebsd-questions@FreeBSD.ORG Subject: Re: cleaning a text file Message-ID: <19990215185722.A21817@dan.emsphone.com> References: <19990215201056.19929@welearn.com.au> <19990216095232.J2207@lemis.com> <19990216103740.60271@welearn.com.au> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.95.1i In-Reply-To: <19990216103740.60271@welearn.com.au>; from "Sue Blake" on Tue Feb 16 10:37:40 GMT 1999 X-OS: FreeBSD 3.0-CURRENT Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In the last episode (Feb 16), Sue Blake said: > The problem is that I don't know which funny characters exist in the > file, if any. I want to find out what they are, so I can search for > them and eyeball them before killing them. How about something like grep "^[ -~]" file.txt That will print any lines that have characters outside the standard printable ascii set. Then you can look at the oddball letters and figure out appropriate replacement characters. -Dan Nelson dnelson@emsphone.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message