in reply to A du(1) real-time sorter using Curses

Cute. I wanted to be able to specify the dir root and use KB for file size:

[root@devel3 root]# diff dutest dutest.patch 3c3,5 < open my( $pipe ), "du -a |"; --- > use constant UNITS => 1024; > my $dir = $ARGV[0] || '.'; > open my( $pipe ), "du -ab $dir |"; 131c133 < $win->addstr( $i, 1, sprintf( "%8d", $self->[$i][SIZE] || ' +' ) ); --- > $win->addstr( $i, 1, sprintf( "%8d", ($self->[$i][SIZE] || +0)/main::UNITS ) ); [root@devel3 root]#

cheers

tachyon