Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re^2: Unix shell ls vs readdir

by jffry (Hermit)
on May 11, 2010 at 03:36 UTC ( [id://839351]=note: print w/replies, xml ) Need Help??


in reply to Re: Unix shell ls vs readdir
in thread Unix shell ls vs readdir

Actually, ls -l /a_dir will not list the contents of a_dir's subdirectories on any Unix flavor that I've used. Maybe you are thinking of ls -l /a_dir/* which will do exactly what you described because the shell will expand the glob "/a_dir/*" and then hand that list of arguments to ls, and, of course, when ls is handed a directory name as an argument it lists the contents of that dir.

But yes, a total forehead slap on the situation with spaces in file names messing up my array ordering. Yet another solid reason to keep it all Perl.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others studying the Monastery: (5)
As of 2024-04-23 20:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found