bash script for replace text from two file in one



I have two file xml; en.xml and it.xml


in the default file language en.xml I have this structure



<string key="City is not set">
<tr lang="en"> City is not set </tr>


in the file It.xml I have:



<string key="Citt&agrave; non &egrave; impostato">
<tr lang="it"> </tr>


In that way I can extract data from it.xml and put in to en.xml ?


from en.xml I need to get string key



<string key="City is not set">


in the second file it.xml I need to change:



<string key="Citt&agrave; non &egrave; impostato">


in to :



<tr lang="it"> Citt&agrave; non &egrave; impostato </tr>


my goal is to obtain a final result:



<string key="City is not set">
<tr lang="it"> Citt&agrave; non &egrave; impostato </tr>


I hope is clear.


No comments:

Post a Comment