Can multi line sed scripts be run???

General questions about using WildEdit

Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard

Post Reply
p40whk
Posts: 3
Joined: Thu May 08, 2003 1:43 pm

Can multi line sed scripts be run???

Post by p40whk »

I have about 1300 lines of SED script to run on about 600 files and am wondering if I can use Wildedit to do this? My script basically searches for any of the first item in quotes and replaces it with the second item in quotes, globally (see below):

1,$s/rg="A-0000000034"/rg="A-055101010"/g
1,$s/rg="A-0000000035"/rg="A-055104010"/g
1,$s/rg="A-0000000036"/rg="A-055107010"/g
1,$s/rg="A-0000000037"/rg="A-055108010"/g
1,$s/rg="A-0000000038"/rg="A-055114010"/g
1,$s/rg="A-0000000039"/rg="A-055115010"/g
1,$s/rg="A-0000000040"/rg="A-055116010"/g

Peviously, we had to break the SED script into multiple scripts of no more than 200 lines and the files we ran the scripts on had to be concatenated together then broken apart after all the scripts were run (a big pain).

I've tried just putting the item in quotes in the find and replace boxes in Wildedit but have had not luck. If anyone out there knows if this can be done and how I would greatly appreciate the help.
User avatar
bbadmin
Site Admin
Posts: 854
Joined: Mon Feb 17, 2003 8:54 pm
Contact:

Post by bbadmin »

WildEdit is an interactive multi-file editor which acts on a single replacement at a time, through a specified set of files. Sed has different capabilities, so I suggest you search for a better implementation of it than the one you are currently using.

Keith MacDonald
Helios Software Solutions
Post Reply