Compare Folders by Last modified Date (PERL)
Could somebody please assist me in comparing last modified dates in Perl?
Currently I have:
use File::stat;
use Time::localtime;
my $fh = "$directory/$file";
my $timestamp = ctime(stat($fh)->mtime);
With timestamps being in the format: Mon May 20 13:46:10 2013
I need to be able to compute a few things:
Folders modified in the past 2 months
Folders modified in the last month
Last 25 folders modified.
I do not necessarily need the timestamps in that format, I will not be using them for any purpose other than for comparing.
Any help is appreciated thanks.
Could somebody please assist me in comparing last modified dates in Perl?
Currently I have:
use File::stat;
use Time::localtime;
my $fh = "$directory/$file";
my $timestamp = ctime(stat($fh)->mtime);
With timestamps being in the format: Mon May 20 13:46:10 2013
I need to be able to compute a few things:
Folders modified in the past 2 months
Folders modified in the last month
Last 25 folders modified.
I do not necessarily need the timestamps in that format, I will not be using them for any purpose other than for comparing.
Any help is appreciated thanks.
No comments:
Post a Comment