tru64-unix-managers (formerly alpha-osf-managers) (1994-2012)
 help / color / mirror / Atom feed
From: Sudhir Oak <oak () crhc ! org>
To: tru64-unix-managers
Subject: Control codes in VI when using replace
Date: Mon, 15 Oct 2001 23:05:23 +0000	[thread overview]
Message-ID: <102653641821856.tru64-unix-managers.marc@archive.invalid> (raw)

I need to replace the line feed (not Ctrl M, but I think it is Ctrl J, it =
shows as a $ sign if you set the set list option on when viewing the file) =
character with ,line feed.  It's a big file=20
I have tried the tr command with
tr -s "\012"  "\054\012" <filein >fileout
This gave me a file replacing converting all records into a big single =
record replacing the linefeed with commas!
When I tried the vi, and used the command level :s command, as soon as I =
type the Ctrl V Ctrl J sequence it escapes the command level and comes =
back with no matching pattern error.
I can import the file into m/s word and then use the replace ^p with ,^p =
and then upload it to Unix and it will work, but I was trying to avoid =
that  extra work.  I have used tr command to replace the Ctrl M with line =
feed tr -s "\015" "\012" but I am not having much success replacing a =
single character with mutiple characters using the tr or any other command =
in vi that I am aware of.
Your response will be greatly appreciated.


Thanks,

Oak
603-230-1160 (CRHC)
860-945-6780 (when working remotely)
203-982-6463 (New Pager eff 10/10/2001)
=20

                 reply	other threads:[~2001-10-15 23:05 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox