On Mar 28, 5:40 am, [EMAIL PROTECTED] (Anders) wrote: > Hi! > I am looking for a way of moving files older than a date,
You can find the number of days since a file was last modified with - M: #! perl use warnings; use strict; opendir (my $dir, ".") or die "$1"; for (readdir ($dir)) { print $_," is ",-M $_," days old.\n"; } Minimal documentation is in "perldoc -f -M". There are also functions for access time (-A) and creation time (-C). It works on Windows too. To move the files, you can use the function "move" from File::Copy. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/