Feature #793
Find File Extension Statistics For a Directory on FreeBSD
Description
I recently needed to find how many of each filetypes existed in a given directory. This is the command I used to get the desired data.
- Find filetype usage in a given directory:
find /path/to/data/ -type f -and -print | egrep -io '\.[^.]*$' | sort | uniq -c | sort -rn
Resources¶
Updated by Daniel Curtis over 8 years ago
- Status changed from New to Resolved
- % Done changed from 0 to 100