3 ms·
Assuming no dups in file1, this outputs lines in file1 that aren't in file2: sort file1 file2 file2 | uniq -u (double file2 is not a typo :)
by hoytech 9y ago
Assuming no dups in file1, this outputs lines in file1 that aren't in file2:
sort file1 file2 file2 | uniq -u
(double file2 is not a typo :)
- isometry 9y agoOr (a little faster): comm -23 <(sort file1) <(sort file2)