using the readdir beforehand make this possible?
-Original Message-
From: Rob Dixon [mailto:[EMAIL PROTECTED]
Posted At: Saturday, December 13, 2003 6:27 AM
Posted To: Perl
Conversation: Getting the most recent file
Subject: Re: Getting the most recent file
[EMAIL PROTECTED] wrote:
I am
At: Saturday, December 13, 2003 6:27 AM
Posted To: Perl
Conversation: Getting the most recent file
Subject: Re: Getting the most recent file
[EMAIL PROTECTED] wrote:
I am trying to write some code to read the most recent log file in a
directory. I wrote some code below. This works but I was wondering
Paul Harwood wrote:
One question I have:
With this statement:
@files = sort { -M $a = -M $b } @files;
How does Perl understand that these are files and not just text entries?
Did using the readdir beforehand make this possible?
Well they /are/ just text entries! But ones that correspond
I am trying to write some code to read the most recent log file in a
directory. I wrote some code below. This works but I was wondering if
there was a more efficient method to do this. Ideally I would like to
include hours, minutes and seconds but that's not necessary at this
point.
--Paul
[EMAIL PROTECTED] wrote:
I am trying to write some code to read the most recent log file in a
directory. I wrote some code below. This works but I was wondering if
there was a more efficient method to do this. Ideally I would like to
include hours, minutes and seconds but that's not necessary