Probably a no-brainer, but I wondered what is the canonical way or
possibly a module that does this chore:

Identify files by type similar to `-type' flag to unix `find' command.
I first thought of the stat function, but I see I'm confused about
what that does.  None of the array elements are about type.

One of them `mode' claims to be about `type' but I'm not conversant
with the numeric output of that element.   And it doesn't seem to be
explained in language spoken by mortals in perldoc -f stat
All the gobbledeegook about bit-anding masking etc would be rendered
unecessary by an (often omitted)  simple example.
There is an example showing how to get the permissions from $mode but
I couldn't begin to reverse engineer it to get type. 


Maybe File::Find has an option but I don't find it in the docs.

Along with this `typing' action I wondered if there is a perl
equivalent to unix `file' command.

I browsed all the modules turned up with a search string of

   file type  
on cpan, but none revealed this functionality.  At least not in a
hasty scan.


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to