Last Updated: February 25, 2016
·
1.372K
· vinitcool76

Better Readable Disk Usage Stats.

Add this alias to the your .bashrc and you will have a more Human readable du stats.

I have aliased it to duf, you can alias it to anything you like.Here is the code:

alias duf='du -sk * | sort -n | perl -ne '\''($s,$f)=split(m{\t});for (qw(K M G)) {if($s<1024) {printf("%.1f",$s);print "$_\t$f"; last};$s=$s/1024}'\'

Here is the link, and here is how it looks like

Picture