If you are using a linux system, the linux workhorse for this kind of thing is the
find->sed replace command. See, for instance:
http://www.brunolinux.com/02-The_Terminal/Find_and%20Replace_with_Sed.html.
Here's a modification of the script given there:
#!/bin/bash
TEXTFILES=`find . -name "*.txt"`
for fl in $TEXTFILES
do
cp $fl $fl.old
# rm -f $fl.old
# sed 's/FINDSTRING/REPLACESTRING/g' $fl.old > $fl
# rm -f $fl.old
done
First create your backups, then comment out the
cp $fl $fl.old and uncomment the sed line with the proper search and replace strings. When you are satisfied you have what you want you can removed the
*.old files by uncommenting
rm -f $fl.old. In each case you have to comment out the commands which are not currently wanted.
You place this script in the topmost directory of the the files you want to change.
I used this basic technique when I was creating the ckgdoku companion to ckgedit and wanted to replace every instance of ckgedit with ckgdoku. There were approximately 40,000 lines of code to parse. It was amazingly fast.