Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: A du(1) real-time sorter using Curses

by tachyon (Chancellor)
on Sep 03, 2004 at 10:53 UTC ( #388242=note: print w/replies, xml ) Need Help??


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

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://388242]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (5)
As of 2019-04-24 16:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    I am most likely to install a new module from CPAN if:
















    Results (122 votes). Check out past polls.

    Notices?