Bookmark and Share

Display the sizes of directories and files in current path

$ du -hcs *
8.6G    dir1
838M    dir2
1.5M    file1
 56K    file2
  • -h to use human-readable sizes
  • -c to display a total size
  • -s to display sizes only for directories and files directly under the current path but not in any subdirectory
blog comments powered by Disqus