I need to get all *.config files in a directory and its sub-directories containing the string MySettings.xru.
In all those files that are found, on only the line containing the string MySettings.xru I need to replace the text db001 with db002.
So, for example, if I have:
RandomSettings.xru someOtherWords Database=db001 blah, blah, blah...
MySettings.xru Lalala Database=db001 blah, blah, blah...
YourSettings.xru Hey yo Database=db001 blah, blah, blah...
The results should be:
RandomSettings.xru someOtherWords Database=db001 blah, blah, blah...
MySettings.xru Lalala Database=db002 blah, blah, blah...
YourSettings.xru Hey yo Database=db001 blah, blah, blah...
Thanks!
UPDATE: Solved it myself.
Here is my solution: