I want to change all the text files in one directory which contains the
string "John" to "Peter" using some unix script. (because there are >100 and i can't vi every file and change it)
sample1.txt
John 10
Mary 20
Mat 50
sample2.txt
John 10
Jeff 40
Mat 50
to
sample1.txt
Peter 10
Mary 20
Mat 50
sample2.txt
Peter 10
Jeff 40
Mat 50
in my unix directory. Are there a way to do it?
Thanks so much for the script.