Hi,
i have to insert the content of source.txt into the searched pattern of the file second.txt.
$cat source.txt
One
Two
Three
.
.
$cat second.txt
This is second file
pattern match start here
pattern match end here
end of the file
so the result will be like this
$cat second.txt
This is second file
pattern match start here
One
Two
Three
.
.
pattern match end here
end of the file
i can able to do with help of head and tail with number count. But as the pattern position is not always in fixed line. so believe the AWK is helpful.
Thanks
Hi ,
Is it possible to use the some variable rather than the "source.txt"(as hardcode) so that we can use it as run time variable.
i tried with -v for variable assignment but failed to do so.