On Jan 10, 2008 9:51 AM, Mike Miller <<a href="mailto:mbmiller@taxa.epi.umn.edu">mbmiller@taxa.epi.umn.edu</a>> wrote:<br>[snip]<br><br>OK, I just had to see how awful this would be in Perl. Not too awful:<br><br>% perl -MFile::Find::Rule -MList::Util=min -le 'print min map -M, find->in(".")'
<br>0.00752314814814815<br><br>This is the number of days that have passed since the most recent file modification. Other variations can be had by changing out "-M" (see perldoc -f -X) and min/max. File::Find::Rule also permits conditional chaining. One problem with this is that File::Find::Rule isn't generally part of the Perl core.
<br><br>Here's a variant that prints the date of the most recent file:<br><br>% perl -MFile::Find::Rule -MList::Util=max -le 'print scalar localtime(max map { (stat($_))[9] } find->in("."))'<br>Thu Jan 10 12:18:42 2008
<br>