Can `ls` show directory sizes?

No, the ls command does not show the sizes of directories. It lists the contents of a directory and provides information about files, but it does not calculate or display the total size of a directory itself.

To see the sizes of directories, you can use the du (disk usage) command. For example, running du -h will show the sizes of directories and their contents in a human-readable format.

0 Comments

no data
Be the first to share your comment!