From owner-freebsd-questions Fri Nov 2 16:26:29 2001 Delivered-To: freebsd-questions@freebsd.org Received: from vallesnet.org (vallesnet.org [194.224.210.5]) by hub.freebsd.org (Postfix) with ESMTP id 4BD5837B408 for ; Fri, 2 Nov 2001 16:26:26 -0800 (PST) Received: from daemon (187-BARC-X47.libre.retevision.es [62.82.17.187]) (authenticated) by vallesnet.org (8.11.5/8.11.5) with ESMTP id fA30PlV09592; Sat, 3 Nov 2001 01:25:52 +0100 Message-ID: <00a401c163fe$94084ee0$0164a8c0@daemon> From: "undergra" To: "Andreas Ntaflos" , "David Loszewski" Cc: References: <20011102172444.L97368@happy.cow.org> <003301c163ef$c4d8ca40$3000b1d8@sickness> <20011103004455.B1274@Deadcell.ANT> Subject: RE: ^M on end of lines Date: Sat, 3 Nov 2001 01:28:14 +0100 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 8bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4807.1700 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4807.1700 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG tr -d "\015" < input-file > output-file ----- Mensaje original ----- De: "Andreas Ntaflos" Para: "David Loszewski" CC: Enviado: sábado, 03 de noviembre de 2001 0:44 Asunto: Re: ^M on end of lines > On Fri, Nov 02, 2001 at 05:43:18PM -0500, David Loszewski wrote: > > Yea, but then I have to do that to all the files > > Not pretty when you have a 100 files > > > > Dave > > > >> a simple fix after dl is to open it up in vi and do > >> :%s,^V^M,,g > >> > >> -r > > The following perl command issued on the CLI will get > rid of these annoying ^Ms. > > # perl -e -i -p 's/\r\n/\n/s' filename > > you can use wildcards too. > > There are also ports to solve these problems, like dos2unix. > > regards > -- > Andreas "ant" Ntaflos > ntaflos.andreas@gmx.net > Vienna, AUSTRIA > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-questions" in the body of the message > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message