text
List directory in Ruby
# List recusirvely all not hidden files and directories in /home/foo
files = `find /home/foo \\( ! -regex '.*/\\..*' \\)`
files.each do |f|
puts f
end
blog comments powered by Disqus