bash - Remove previous line to a match string? -
How can I remove the last line of a match pattern?
or
Contrast:
sed -n '/ pattern / {g; 1! P;}; H '
You can return the file and then return the line after the matte pattern (Which is simple), and then return the result, here is the code:
tail-r | SAD / Pattern / {n; D;} 'tail-r
Comments
Post a Comment