Recursively counting files (linux)

I never realised ls was such a powerful little ‘ol command, need to know how many files in a directory and also sub directories, try this one on for size…

ls -laR | wc -l

Leave a Reply

Your email address will not be published. Required fields are marked *