Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: Alternative for a directory builder

by Eliya (Vicar)
on Feb 22, 2011 at 18:50 UTC ( #889655=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my $_=$a;  say while s|[^/]+/*$||;
    
    ...
    /aaaa/bbbb/
    /aaaa/
    /
    
  2. or download this
    my @dirs;
    my $_=$a;  push @dirs, $_ while s|[^/]+/*$||;
    ...
    /aaaa/bbbb/
    /aaaa/bbbb/cccc/
    /aaaa/bbbb/cccc/dddd/
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://889655]
help
Chatterbox?
[GotToBTru]: you could, yes
[GotToBTru]: whether or not it would be the best tool for that job .. that is another question

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (9)
As of 2017-02-22 18:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Before electricity was invented, what was the Electric Eel called?






    Results (335 votes). Check out past polls.