I have file1 which has data as follows:
url1
url2
url3
url4
.
.
.
file2 has data as below:
xml1
xml2
xml3
.
.
.
I want to merge these two files and the merged file say file3 should look below:
url1
xml1
url2
xml2
url3
xml3
url4
xml4
I have file1 which has data as follows:
url1
url2
url3
url4
.
.
.
file2 has data as below:
xml1
xml2
xml3
.
.
.
I want to merge these two files and the merged file say file3 should look below:
url1
xml1
url2
xml2
url3
xml3
url4
xml4
This should do:
while read -r file1 && read -r file2 <&3; do
echo "$file1"; echo "$file2"
done <file1.txt 3<file2.txt