Tough not to mention a un*x golf solution ;)
$ comm -12 <(sort FILE1) <(sort FILE2) > OUT # comm gives 3 cols # 1: lines only in first file # 2: lines only in second file # 3: common lines # flag -# suppresses col#
magic <(...) is to save a temporary file. If your shell does not support it just do 'sort FILE1 -o FILE1.s' comm needs sorted files for its magic.
cheers --stephanIn reply to Re: remove entries that match
by sgt
in thread remove entries that match
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |