Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 5 May 2006 15:21:55 +0200
From:      Riemer Palstra <riemer@palstra.com>
To:        Aguiar Magalhaes <magalhj@yahoo.com.br>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Substitute command on vi
Message-ID:  <20060505132155.GC36379@rb1.palstra.com>
In-Reply-To: <20060505131202.44990.qmail@web31608.mail.mud.yahoo.com>
References:  <20060505131202.44990.qmail@web31608.mail.mud.yahoo.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, May 05, 2006 at 10:12:02AM -0300, Aguiar Magalhaes wrote:
> I need to substitute a lot of characters ^M (ctrl+M)
> at the end of each line in my file.

You might wanna give dos2unix a try: /usr/local/bin/dos2unix

> The command :%s/^M//g insn't have success.

Is this a shift+6 M, or a ctrl+V ctrl+M? The last one should work.

-- 
Riemer Palstra		     		      Amsterdam, The Netherlands
riemer@palstra.com				 http://www.palstra.com/



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