Is there a way to select only those lines from a text file which exclude a substring?For example, I have the file:
I have a /apple
I have a peach
I have a cucumber/strawberry
ABCDE
I have a apple/grape
XYZEF
POLSD
and i want to select the lines that start with 'I have a' but don't include the string 'apple'.So basically I want to select only:
I have a peach
I have a cucumber/strawberry