Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 4 Aug 2003 10:13:52 -0500
From:      "Munden, Randall J" <Randall.Munden@umb.com>
To:        "C Peter Biessener" <pbiessener@hirshfields.com>, <freebsd-questions@freebsd.org>
Subject:   RE: How to remove ^M character
Message-ID:  <79B4EAB03B5E4649A740A8C1452F60643522F0@y6001au.umb.com>

next in thread | raw e-mail | index | archive | help
Or, if you've perl available:

perl -pi -e 's/\r\n/\n/;' [file name]

-----Original Message-----
From: C Peter Biessener [mailto:pbiessener@hirshfields.com]=20
Sent: Monday, August 04, 2003 10:09 AM
To: freebsd-questions@freebsd.org
Subject: Re: How to remove ^M character


You can also use ASCII mode in ftp, it will translate the line ends for=20
you.  BINARY mode is for programs and archive files (zip, tar, tgz,
etc...)

Simon Barner wrote:
> Hi,
>=20
>=20
>>I ftp'd a file from windows to freebsd....not its every line has ^M at

>>its end. Is there some command in vi (or some way) by whcih ^M can be=20
>>removed.
>=20
>=20
> You can use dos2unix(1) for that. There is also the complementary tool

> unix2dos(1).
>=20
> Simon

_______________________________________________
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to
"freebsd-questions-unsubscribe@freebsd.org"



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?79B4EAB03B5E4649A740A8C1452F60643522F0>