Eric on 21 Apr 2006 23:31:38 -0000

[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

[PLUG] Perl question

In the shell I can easily compare the dates of two files:

$  if [ .y2log -nt .y2log-1 ]; then
     echo .y2log is newer than .ylog-1
     echo .y2log is older than .ylog-1
.y2log is newer than .ylog-1

So what is the similar perl idiom for comparing file dates?

I have to compare 166,000 (+) pairs of files and I'd rather
do it with perl.  Particularly since I open the directory
and read the filenames into a hash which turns out to be
wicked-fast for processing the file names.



#  Eric A Lucas
#  ------------
#   "Oh, I have slipped the surly bond of earth
#    and danced the skies on laughter-silvered wings... 
#        -- John Gillespie Magee Jr.
Philadelphia Linux Users Group         --
Announcements -
General Discussion  --