I want to get a list of all files in a directory that contain multiple sub-directories (and p开发者_如何学编程ossible more sub-directories within them)
How can I do this using Ruby on my Mac OS X?
Thanks
Something like this should work
Dir["**/*"].select{|x| !File.directory?(x)}
精彩评论