Come for the quick hacks, stay for the epiphanies. | |
PerlMonks |
Re: Large scale search and replace with perl -iby neilwatson (Priest) |
on Apr 14, 2003 at 18:55 UTC ( [id://250376]=note: print w/replies, xml ) | Need Help?? |
Try this:
find / -name "*.html" -exec perl -pi -e 's/find/replace/gi' {} \;
Update Ooops reread your questions. Hmmm, not sure about ignoring certain files. However, does filtering your find file list through grep really gain you any speed? You are having grep go through all your files and then have perl go through whatever files grep returns.
Neil Watson
In Section
Seekers of Perl Wisdom
|
|