[thelist] find and replace text in multiple files under Linux
Dean Mah
dmah at members.evolt.org
Fri May 24 12:45:03 CDT 2002
With Perl you can do:
perl -pi~ -e 's/foo/bar/' [files]
from the command-line. 's/foo/bar/' is the Perl regexp substitution
operator. A backup of the file should be saved as filename~.
Dean
On Fri, May 24, 2002 at 12:40:03PM -0500, Samir M. Nassar wrote:
> I have a 20+ page project and doing a find and replace on each page is
> tedious.
>
> So I come to thee o evoltian oracles in hope of findding a solution.
>
> Do you guys know of/have a script or binary that can do file and replace
> on multiple files?
>
>
> Samir M. Nassar
More information about the thelist
mailing list