I have the following code:
cat file | grep example | sed 's/http/https/' >> report.txt
Output of that command:
This will add a link, with HTTPS, to the file. I would like, however, for that same output to also replace "URL" in a second file.
Content of the second file:
TEXT TEXT TEXT URL TEXT TEXT
Desired change in second file:
TEXT TEXT TEXT https://example.com/page/index.html TEXT TEXT
Is this possible?
P.S.: I can't repeat the command again, as it is actually not a simple cat but an upload process that starts the command.