[PLUG] To the VI Question
Matt Alexander
m at netpro.to
Mon Jul 15 20:10:27 UTC 2002
OK, now I'm confused... Even when I manually edit a file, create a list
of names and hit the enter key after each one, then try the substitute, it
doesn't work. Any guesses as to what the problem could be?
Thanks,
~M
P.S. The :%s only replaces the first occurance of what you're searching
for in each line. To replace every occurance in a line, you would use:
:%s/old/new/g
On Mon, 15 Jul 2002, Sean Whitney wrote:
> Actually that worked for me
>
> :%s/\n/,/
>
> However more correct is
>
> % - apply to all lines in the file
> s - substitute
More information about the PLUG
mailing list