January 2004
Intermediate to advanced
368 pages
7h 25m
English
While the ls command is a cornerstone of working with the Unix command line, there's one element of the command that's always seemed pointless to me: indicating the size of a directory. When a directory is listed, the program either lists the directory's contents file by file or shows the number of 1,024-byte blocks required for the directory data. A typical entry in an ls -l output might be
drwxrwxr-x 2 taylor taylor 4096 Oct 28 19:07 bin
But that's really not very useful, because what I want to know is how many files are in the specified directory. That's what this script accomplishes, generating a nice multicolumn listing of files and directories that shows file size with file entries and ...
Read now
Unlock full access