Home > Archive > PERL Beginners > July 2007 > obtaining file properties
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
obtaining file properties
|
|
| Sam DeForest 2007-07-15, 4:00 am |
| Hi folks, noob here...
Im looking to produce a script that will return to me some file properties in windows. I know for unix I can use 'stat'. The only thing that comes close (as i can find right now) is use of the Win32::File module. However that would just return the attributes. Im looking to find "size" and "create date/time". Could someone point me in a good direction so I can read into further?
I appreciate the help,
Sam
| |
| Ken Foskey 2007-07-15, 4:00 am |
| On Sun, 2007-07-15 at 01:05 -0400, Sam DeForest wrote:
> Hi folks, noob here...
>
> Im looking to produce a script that will return to me some file properties in windows. I know for unix I can use 'stat'. The only thing that comes close (as i can find right now) is use of the Win32::File module. However that would just return the at
tributes. Im looking to find "size" and "create date/time". Could someone point me in a good direction so I can read into further?
> I appreciate the help,
size is dead easy -s filename
--
Ken Foskey
FOSS developer
| |
| yaron@kahanovitch.com 2007-07-15, 4:00 am |
| Hi,
You can use File::stat.
perldoc -f stat
or
http://search.cpan.org/~nwclark/per...ib/File/stat.pm
Yaron Kahanovitch
----- Original Message -----
From: "Sam DeForest" <sam.ml@walpolewood.net>
To: beginners@perl.org
Sent: Sunday, July 15, 2007 8:05:15 AM (GMT+0200) Auto-Detected
Subject: obtaining file properties
Hi folks, noob here...
Im looking to produce a script that will return to me some file properties in windows. I know for unix I can use 'stat'. The only thing that comes close (as i can find right now) is use of the Win32::File module. However that would just return the attr
ibutes. Im looking to find "size" and "create date/time". Could someone point me in a good direction so I can read into further?
I appreciate the help,
Sam
|
|
|
|
|