[TriLUG] Perl Question
William Sutton
william at trilug.org
Mon Jul 31 17:00:22 EDT 2006
next if (-s $file) == 0;
:)
--
William Sutton
M: 919.604.2502
On Mon, 31 Jul 2006, Mark Freeze wrote:
> Can anyone give me a tip on finding the size of a file with perl?
>
> I am using the following method to parse through a list of files
> within a specific directory after using readdir.
>
> foreach $listitem (@contents)
> {
> ...do some stuff to each file...
> }
>
> What I'd like to do is skip over any file that has a size of zero.
>
> Thanks,
> Mark.
>
More information about the TriLUG
mailing list