How to remove ^M character

Karl Pielorz kpielorz at tdx.co.uk
Fri Aug 1 01:37:35 PDT 2003



--On 01 August 2003 14:01 +0530 Anil Garg <anilg at niksun.com> wrote:

> Hi,
>
> 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 which ^M can be removed.

man tr

or simply,

cat file | tr -d "\r" > newfile

-Kp


More information about the freebsd-questions mailing list