Here is a simple way to find out how many files, directories and links are in current directory:

ls -l | grep ^- | wc -l
ls -l | grep ^d | wc -l
ls -l | grep ^l | wc -l

Comments are closed.

Post Navigation