Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 11 Jan 1999 06:32:31 -0500
From:      "Larry S. Marso" <larry@marso.com>
To:        charon@freethought.org, freebsd-questions@FreeBSD.ORG
Subject:   Re: replacing ^M in vi
Message-ID:  <19990111063231.M19337@marso.com>
In-Reply-To: <3.0.5.32.19990110225910.00a2f220@mail>; from charon@freethought.org on Sun, Jan 10, 1999 at 10:59:10PM -0800
References:  <3.0.5.32.19990110225910.00a2f220@mail>

next in thread | previous in thread | raw e-mail | index | archive | help
I believe one of the mtools apps does this automatically as you copy text
files from your freebsd machine to a floppy disk.

Best regards
-- 
Larry S. Marso
larry@marso.com



On Sun, Jan 10, 1999 at 10:59:10PM -0800, charon@freethought.org wrote:
> Whenever I save a plain text file in WinNT and open it in FreeBSD, at the
> end of every line is a "^M".  How do I get rid of these?  I tried writing a
> little C++ program to copy all text except "^M" to another file, but it
> doesn't work because C++ treats the ^ and the M as different characters,
> whereas vi treats them as _one_ character.  After searching the mailing
> list archives, I came up with the syntax ":%s/stuff/other stuff/g" as the
> oh-so-intuitive replace command in vi, and I tried it, but to no avail (it
> says "no match found").  Any suggestions?  Thanks,
> 
> 
> 
>         Charon@freethought.org
>  http://members.home.net/tuathadedanann/
> 
>    alt.sex.fetish.hamster.duct-tape
> 
> 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



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