$ ls -A1 /path/to/folder | wc -l
Lists out the files in a directory including hidden files in a single-column format and pipes it through a line count via wc.
- sandip's blog
- Login or register to post comments
$ ls -A1 /path/to/folder | wc -l
Lists out the files in a directory including hidden files in a single-column format and pipes it through a line count via wc.