Tuesday 6 November 2012

Remove lines from file 1 that are in fiel 2




grep -v -x -f f2 f1 should do the trick.

With some explanations:

-v for select non-matching lines
-x for matching whole lines only
-f f2 to get patterns from f2.

No comments:

Post a Comment