Block oriented search and replace across multiple files.

Ray Parrish crp at cmc.net
Sat Nov 28 15:10:21 UTC 2009


Kenneth Loafman wrote:
> Ray Parrish wrote:
>   
>> Hello,
>>
>> I am searching for a programmer's editor that does block oriented 
>> search, and replace across multiple files. I have found regexxer, but it 
>> only changes single lines at a time, and will not match a multi-line 
>> search term.
>>
>> What I want to be able to do is replace several lines of text with 
>> several other lines of text in all open files all at one go.
>>
>> Does anyone know of an editor that does this?
>>     
>
> Emacs and Eclipse both support multi-line regex expressions.  I'm rusty
> on Emacs, but with Eclipse just use "(?ms)StartPhrase.*StopPhrase" to
> match the paragraph, then replace with whatever you want.  Add anchors
> as needed.
>
> ...Ken
>   
Hello,

I have Eclipse on here, but it is a bit over the top for what I want to 
do, which is make broadcast changes to my web site's pages. I'm going to 
forego the learning curve, and the necessity to remember regular 
expressions by writing my own multi document, block oriented search, and 
replace program that will allow me to paste in what I want to replace, 
and paste in what I want it replaced with, and the program will take 
care of searching, and replacing for me.

I should have it done by the end of the day, whereupon I will release it 
on my site as open source software for Linux. Maybe by the end of 
tomorrow, it depends on whether or not I get stuck anywhere.

Later, Ray Parrish

-- 
The Future of Technology.
http://www.rayslinks.com/The%20Future%20of%20Technology.html
Ray's Links, a variety of links to usefull things, and articles by Ray.
http://www.rayslinks.com
Writings of "The" Schizophrenic, what it's like to be a schizo, and other
things, including my poetry.
http://www.writingsoftheschizophrenic.com






More information about the ubuntu-users mailing list