in reply to comparing files based on timestamps
Using stat() function we can get it.
Let's try this example,
#! /bin/perl
use strict;
my ($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size, $atime,$ctime,$blksize,$blocks) = stat("subfolder1");
print "$atime\t$mtime\t$ctime\n";
my ($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size, $atime,$mtime,$ctime,$blksize,$blocks) = stat("Library");
print "$atime\t$mtime\t$ctime\n";
For more details see "perldoc -f stat".
|
---|
In Section
Seekers of Perl Wisdom