[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ale] Quick substitution question
- Subject: [ale] Quick substitution question
- From: esoteric at denali.atlnet.com (Wandered Inn)
- Date: Wed, 13 Dec 2000 10:21:03 -0500
Armsby John-G16665 wrote:
>
> I have a large file which has tab delimited information per line.
>
> Can some blast out a quick vi command to substitute a pipe | for the tab \t ?
>
> This does not work.... :%s/\t/|/g
try:
:1,$ s/ /|/g # where there is a literal tab following the 's/' this
worked for me.
or
:g/ /s//|/g # again, just hit the tab key following the 'g/' this also
worked for me.
>
> I am trying to make this simple for others in my group. I would prefer not to use perl or awk, etc. I know they can do it but I am considering those who will follow me here...
>
> thanks,
>
> John
> --
> To unsubscribe: mail majordomo at ale.org with "unsubscribe ale" in message body.
--
Until later: Geoffrey esoteric at denali.atlnet.com
"Great spirits have always found violent opposition from mediocre minds.
The
latter cannot understand it when a man does not thoughtlessly submit to
hereditary prejudices but honestly and courageously uses his
intelligence."
- Albert Einstein
--
To unsubscribe: mail majordomo at ale.org with "unsubscribe ale" in message body.