A find and replace script using perl

perl -pi -e 's/find/replace/g' *.txt

Or, to change matching files in a hierarchy:

find . -name '*.txt' |xargs perl -pi -e 's/find/replace/g'