i’m trying to write a grep/sed/awk for a condition from a file, and at the same time with a negative condition (does not contain xxx) and also i wanna grep all the lines that are > than a certain line number.
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Awk should deal with that nicely:
I wasn’t quite certain if all the conditions were applied together. I guessed that you always want to print lines beyond some point, but up to that point the positive and negative conditions applied.