From owner-freebsd-stable Mon May 3 12:44:23 1999 Delivered-To: freebsd-stable@freebsd.org Received: from paprika.michvhf.com (paprika.michvhf.com [209.57.60.12]) by hub.freebsd.org (Postfix) with SMTP id 98DA7151E0 for ; Mon, 3 May 1999 12:44:19 -0700 (PDT) (envelope-from vev@michvhf.com) Received: (qmail 10696 invoked by uid 1001); 3 May 1999 19:44:21 -0000 Message-ID: X-Mailer: XFMail 1.3 [p0] on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <19990503143252.C7049@holly.dyndns.org> Date: Mon, 03 May 1999 15:44:21 -0400 (EDT) X-Face: *0^4Iw) To: freebsd-stable@FreeBSD.ORG Subject: Re: Dos2unix Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On 03-May-99 Chris Costello wrote: > On Mon, May 3, 1999, Michael C. Vergallen wrote: >> Here it is ... someone gave me this routine to use ... > > This code is both unnecessarily complex and it does not > function the same way the BSDI dos2bsd/bsd2dos tools work. This is all I use in a shell script to convert to unix. tr -d '^M' < $1 But change the ^M to an actual ASCII 13. I call it 2ux and to use it: 2ux INFILE > OUTFILE I've never bothered converting them back, if needed I just load it into an editor on the dos machine and save it, but you can probably use tr or sed to do that if you really needed to. Vince. -- ========================================================================== Vince Vielhaber -- KA8CSH email: vev@michvhf.com flame-mail: /dev/null # include TEAM-OS2 Online Campground Directory http://www.camping-usa.com Online Giftshop Superstore http://www.cloudninegifts.com ========================================================================== To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message