Online Games Grumpy Unix Fart Contact Us

NAME

du_file - Display disk usage by file type.

DESCRIPTION

Use this program to display disk usage statistics based on filetype.

It'll tell you how many bytes are in use by mp3 files, gif files, html documents, etc..


USAGE

  du_file.pl /one /two /three

Sum up the usage of the three directories (if they exist) and report the usage, by filetype.

SAMPLE OUTPUT





                       DISK USAGE BY FILE EXTENSION.
    Prepared: Tue Nov  7 05:55:16
    Path:     /home/joe/perl/text
    File Type                        Files              Bytes
    ---------                        ---------          ----------------
    db                                        1                  9.88 M
    swp                                       1                 12.00 K
    cgi                                       1                  5.97 K
    pl                                        2                  3.19 K
    pm                                        1                  1.97 K

Download

Just download the source code and run it with perl:

  perl du_file.pl /usr/local/

It'll give you a report of your files in /usr/local


Send to a friend

[add]
Please enter code (Change Code)

Sending Message.