Please enter filesystem name in the form of '/fsname' /cygdrive/c/temp Use of uninitialized value in concatenation (.) or string at file_find +.plx line 24, <> line 1. Use of uninitialized value in concatenation (.) or string at file_find +.plx line 24, <> line 1. Use of uninitialized value in numeric comparison (<=>) at file_find.pl +x line 24, <> line 1. Use of uninitialized value in numeric comparison (<=>) at file_find.pl +x line 24, <> line 1. FileSize in Bytes FileNames over 25 Mbytes =================================================================== 33502125: /cygdrive/c/temp/Setup/Pattern/Share/0x0000000 +4/Copy of lpt$vpn.701 =========================================================== 33502125: /cygdrive/c/temp/Setup/Pattern/Share/0x0000000 +4/lpt$vpn.701
#!/usr/bin/perl use strict; use warnings; use Readonly; use File::Find; use File::Find::Closures qw(:all); #use Data::Dumper; my (@sorted_large_files,@large_files); print qq (\nPlease enter filesystem name in the form of '/fsname'\n); my $fs = <>; chomp ($fs); my @directory = qq($fs); Readonly::Scalar my $t25Mb => 26500000; my( $wanted, $list ) = find_by_min_size ( qq($t25Mb) ); File::Find::find ( { wanted => $wanted, }, @directory ); @large_files = $list->(); @sorted_large_files = sort { -s "$_/$b" <=> -s "$_/$a" } @large_files; print "\nFileSize in Bytes\tFileNames over 25 Mbytes\n"; print map { '=' x length $_,"\n", -s $_,":\t\t$_\n" } @sorted_large_files;
In reply to File::Find::Closures... help by mikejones
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |