I have a file with many lines, a loop that goes each line and a counter.
I want to delete a specific line after an if statement.So the number of the line is in the counter.But I dont know how to write it.I tried something like this :
sed "$counter" d phones
counter is the variable
d is the parameter for sed in order to delete
phones is the file
Any tip appreciated.