Skip to content

Instantly share code, notes, and snippets.

@gwpl
Created December 5, 2018 23:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gwpl/0bf0d8f9aa9385207d3636d130739f10 to your computer and use it in GitHub Desktop.
Save gwpl/0bf0d8f9aa9385207d3636d130739f10 to your computer and use it in GitHub Desktop.
#cli #linux #snippet
# find lines only in file1
comm -23 file1 file2
# find lines only in file2
comm -13 file1 file2
# find lines common to both files
comm -12 file1 file2
https://stackoverflow.com/a/26619069/544721
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment