in reply to How do I determine if a file was modified today?
You should also test against "-C". -M will catch if the file is modified, but what if someone copies up a file right before the script is run? It will give the time since modified, but not sice it was copied up. I think it's better to test both..
I use..
$age = int( -M ) < int( -C ) ? int( -M ) : int( -C );
Rich
|
---|
In Section
Seekers of Perl Wisdom