Hi
I want to find a line in a file which contains a word and replace the patterns.
Sample file content temp.xml
<applications>
<application>
Name="FirstService"
location="http://my.website.selected/myfirstService/V1.0/myfirst.war"
</application>
<application>
Name="FirstService"
location="http://my.website.selected/mysecondService/V1.0/mysecond.war"
</application>
</applications>
Now, I want to search a work "myfirstService" in above file and replace the line with say location="/home/usr/st.war"
.
Same way.. I want to search a word mysecondService and replace with say location="/home/usr/sn.war"
Thanks,
Sakthi