Display the size of all your home's directories

du -sh ~/*
Display the size (human reading) of all the directories in your home path (~).
Sample Output
896K	/home/labo/bin
4,0K	/home/labo/Bureau
197M	/home/labo/dev
710M	/home/labo/Documents
381M	/home/labo/Dropbox
24K	/home/labo/flumotion
964M	/home/labo/Images
4,0K	/home/labo/Mod?les
4,0K	/home/labo/Musique
4,0K	/home/labo/Public
2,4G	/home/labo/qemu
19M	/home/labo/src
355M	/home/labo/T?l?chargements
243M	/home/labo/tmp
203M	/home/labo/Vid?os

2010-11-05 10:20:16

What Others Think

More useful is: du -s ~/* | sort -n | tail Will give you the biggest 10 directories in you home path
xplora1a · 577 weeks and 4 days ago
Not all of them. Hidden directories are not shown. Especially in $HOME this can be a serious amount of space. du -h --max-depth=1 ~ That also shows the total at the end. Change ~ to any directory or leave it out for the current directory.
houghi · 577 weeks and 4 days ago

What do you think?

Any thoughts on this command? Does it work on your machine? Can you do the same thing with only 14 characters?

You must be signed in to comment.

What's this?

commandlinefu.com is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.

Share Your Commands

Stay in the loop…

Follow the Tweets.

Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.

» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10

Subscribe to the feeds.

Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):

Subscribe to the feed for: