Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: how to get the all the subdirectories path from the directory

by rinceWind (Monsignor)
on Mar 09, 2006 at 08:45 UTC ( #535349=note: print w/ replies, xml ) Need Help??


in reply to how to get the all the subdirectories path from the directory

If you are looking at alternatives, you might like to try my File::Wildcard, which gives you an object that you repeatedly call $obj->next on, which returns each file name in turn.

You have control of the sort order of each directory, the ellipsis ordering, i.e. whether you want to see subdirectories first or afterwards, and you can use a regex to filter the list and give you just the files that you want. You can even use $1, $2, etc. captures in the regex to construct a array of new filenames.

Enjoy

--

Oh Lord, won’t you burn me a Knoppix CD ?
My friends all rate Windows, I must disagree.
Your powers of persuasion will set them all free,
So oh Lord, won’t you burn me a Knoppix CD ?
(Missquoting Janis Joplin)


Comment on Re: how to get the all the subdirectories path from the directory

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://535349]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (11)
As of 2014-07-23 11:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (140 votes), past polls