develooper Front page | perl.beginners | Postings from December 2002

Putting output back in the same file it came from

Thread Next
From:
Dylan Boudreau
Date:
December 10, 2002 12:03
Subject:
Putting output back in the same file it came from
Message ID:
008a01c2a087$3ccd93d0$0400a8c0@dylan
Here is what I am trying to do.  I want to read all the files in a
directory searching for a specific string, if the string is found I want
it to be either changed or deleted depending on what I enter as a
replacement string.  I know I can do it by putting the output to a
separate file and then just copying the new file over the old one but is
there a way I can just change/delete that string in the original file?
 
Thanks,
 
Dylan

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About