Skip to content

Instantly share code, notes, and snippets.

@ryangreenberg
Created April 16, 2012 22:23
Show Gist options
  • Save ryangreenberg/2402054 to your computer and use it in GitHub Desktop.
Save ryangreenberg/2402054 to your computer and use it in GitHub Desktop.
Find the longest file
find . -type f | # find all normal files
grep -v "\.log$" | # skip files ending with .log
xargs wc -l | # run wc -l on each file
sort -r # sort descending
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment