🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.unix.shell
Article #1164

Re: changing a ! to a \nC where \n is a newline

#1164
From: Conor P. Cahill
Date: Tue, 18 Sep 1990 02:36
12 lines
947 bytes
In article <5015@alpha.cam.nist.gov> coleman@cam.nist.gov (Sean Sheridan Coleman X5672) writes:
>I am trying to use the global substitution power in vi to 
>replace every occurrence of ! with a newline and a C (\nC)

:1,$s/!/<ctrl>-V<Return>C/g	(this will appear as:1,$s/!/^MC/g)



-- 
Conor P. Cahill            (703)430-9247        Virtual Technologies, Inc.,
uunet!virtech!cpcahil                           46030 Manekin Plaza, Suite 160
                                                Sterling, VA 22170 
Technical Details
Message-ID: <1990Sep18.023649.1336@virtech.uucp>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!virtech!cpcahil
References: <5015@alpha.cam.nist.gov>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!virtech!cpcahil
From: cpcahil@virtech.uucp (Conor P. Cahill)
Newsgroups: comp.unix.shell
Subject: Re: changing a ! to a \nC where \n is a newline
Keywords: vi
Message-ID: <1990Sep18.023649.1336@virtech.uucp>
Date: 18 Sep 90 02:36:49 GMT
References: <5015@alpha.cam.nist.gov>
Reply-To: cpcahil@virtech.UUCP (Conor P. Cahill)
Organization: Virtual Technologies Inc., Sterling VA
Lines: 12