Hi all,
I am having some problems and I can't seem to get it right. In short, I
want to only modify text in a specific section. That section is denoted by
the following
<snip>
*DESCRIPTION
<multiple line of text to be edited>
*END
<snip>
Here is what I have. I know the problem, I am reading this line by line so
when I find the DESCRIPTION I drop into the loop, but because I still have
DESCRIPTION obviously I won't search and replace.
open (RUNSET, $FLOW) || die "Can't access $FLOW[0][1]\n";
while (<RUNSET>) {
if ($_ =~ m/DESCRIPTION/){
print "Entering description block";
until ( $_ =~ m/END\.){
print "Entering until";
# next if /;/ # Remove Comments
s/^\ INDISK\s+=.*/ INDISK = $FILENAME ; SMK /;
s/^\ PRIMARY\s+=.*/ PRIMARY = $CELLNAME ; SMK /;
}
}
print TEMPFLOW "$_";
# push @runset, $_ ;
}
I know there must be a way to do this. I know I could get messy by using a
flag, but I'm sure there is a better way. Would anyone mind helping me out
on this?
Thanks
--
Steven M. Klass
Physical Design Manager
National Semiconductor Corp
7400 W. Detroit Street
Suite 170
Chandler AZ 85226
Ph:480-753-2503
Fax:480-705-6407
[EMAIL PROTECTED]
http://www.nsc.com
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]