From: J�rgen Exner on 12 May 2010 20:47
Michael Friendly <friendly(a)yorku.ca> wrote:
>I'm wondering if there is a perl script or a simpler way to accomplish
>the task of doing global search/replace in all files, possibly of
>specified file types in a file tree, where *only* the files that match
>the search string will be modified (because I need to preserve time
>stamps so that only truly modified files will be rsync'd with a server).
File::Find is your friend. In the wanted() function you can specify
whatever search criteria comes to your mind.
First | Prev |
Pages: 1 2
Prev: FAQ 8.42 How do I make a system() exit on control-C?
Next: FAQ 3.30 What's MakeMaker?