gringomike
Technical User
Hi all,
I'm trying to insert a new line after the text "sometext="" appears on a line of a file.
I've tried a few things using sed (including the lines below) but nothing has worked so far.
cat path/to/file/file1.txt |sed 's/^sometext="//' >> /path/to/file/a.txt
cat path/to/file/file1.txt |sed 's/^sometext="/"\n"/' >> /path/to/file/a.txt
Am I on the right lines here or am I way off the mark!?
Thanks
GM
I'm trying to insert a new line after the text "sometext="" appears on a line of a file.
I've tried a few things using sed (including the lines below) but nothing has worked so far.
cat path/to/file/file1.txt |sed 's/^sometext="//' >> /path/to/file/a.txt
cat path/to/file/file1.txt |sed 's/^sometext="/"\n"/' >> /path/to/file/a.txt
Am I on the right lines here or am I way off the mark!?
Thanks
GM