in reply to Using File::Find with a bit of elegance
sub indexfiles { my $cod = shift || die "Must supply filename!"; my @dirs = @_ ? @_ : "."; open(DB, ">$dbpath/$cod.txt") or die "Error: $!"; my $fh = select(DB); local $\ = "\n"; find( sub { local $_ = $_; print if s/\.mp3$//; }, @dirs); close DB; select($fh); }
---------- ooo O\O ooo tilly was here :,(
|
|---|