Craig,
Take a look at File::Find. it allows you to have a subroutine called for each file encountered in a directory tree. You can then build a hash of file extensions and increment the size in there. the documentation is quite good, play with it for a little bit and you should have your script done before you know it. Chuck >This question will be used for win32 file tree but will also apply to unix so I am posting here. > >We have had a request to generate a report for total space usage by file type (extension) within a directory tree. > >Eg: Start at the top of the tree, look at all the file types by extension and then take the file size and total the >file sizes by extension. The report will list the file extension and the total file space used by that extension on >the system. > >I need a sample script or a path to follow to complete this task. I really do not know where to start. > >Any help would be appreciated. > >Thanks, > >Craig A. Sharp _______________________________________________ Perl-Unix-Users mailing list. To unsubscribe go to http://listserv.ActiveState.com/mailman/subscribe/perl-unix-users