I want to search a directory of log files and populate a list of those log files ONLY 
if they match today's date (localtime).
 
$logs = 'c:\logs\W3SVC1';
opendir LOGS, "$logs" or die "Can't open directory:  $!\n";
my @files = grep /\.TXT$/, readdir LOGS;
 
#Right here, I am wondering if there is a simple way of populating @files by using a 
date comparison operation of each file to the local time. I've tried long complicated 
methods of using 'stat' and Time::Local but I was hoping for a simpler solution. 
 
Any help is greatly appreciated.
 
--Paul
 
 

Reply via email to