Negation

Hello, have anybody any idea, how to negate some expression?

I have code that greps somethnig and I want filter from it some results...How to make it?

IDontWantThisExpression=$1
grep 'some regex' | grep '$IDontWantThisExpression' testfile.txt

Thanks for any advices.

Faculty of Mathematics and Physics, Charles University in Prague, The Czech Republic, Ondrej Tichy, ms.mff.cuni.cz/~ticho6am

grep -v <IDontWantThisExpression> filename

yes! -v switch :slight_smile: thanks :slight_smile: