Skip to content

Instantly share code, notes, and snippets.

@sephraim
Last active November 11, 2016 22:45
Show Gist options
  • Save sephraim/0a3aeb83b995e2043f0f52cc84378a34 to your computer and use it in GitHub Desktop.
Save sephraim/0a3aeb83b995e2043f0f52cc84378a34 to your computer and use it in GitHub Desktop.
Print duplicate lines based on first N columns
grep -wFf <(cut -f__COL1__-__COL2__ __FILE__ | sort | uniq -d) __FILE__
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment