I try to find a line in a text file and delete the next line.
I've tested the following code (and some variations) but I'm stuck at the sed command not taking the $ from the stdin therefore not making what I need.
cat test.txt | grep -in mystring | awk -F: '{print $1+1}' | sed -i "$,1d" test.txt