my $rule = File::Find::Rule->new; $rule->file; $rule->name( '*.tmp' ); #find all xml files $rule->mtime("<$timeback"); my @files = $rule->in( $startdir ); ##give me all xml files dating +past $daysback from $startdir ## subroutine me? ## what to do with it my $file = "output.log"; open (OUT,">$file"); foreach (@files) { print OUT $_."\n"; ## move and tar it here } close (OUT);
In reply to stream results directly to a file by bengmau
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |