I have a text file test.txt that has entries in it such as the following:
a line of text
another line
asdf
vkqaoc
coeiam
cieksm
pqocqoci
xmckdow
cqpszls
etc
etc etc etc
I need to search for a line and change the line that comes after it. I have come up with the following using awk that returns the line I want to change but I'm not that good with awk and I need a way to modify that line:
awk '/cieksm/{getline; print}' ./test.txt
pqocqoci
How can I modify that line using awk to say pqocqoci-changed
or is there a better way? Assistance greatly appreciated and thank you!