lyuehh
4/10/2013 - 8:56 AM

bin.rb

#!/usr/bin/env ruby
path =  ENV['PATH'].split(':')

all = []
path.each do |p|
  all.push(Dir.entries(p))
end
puts all.flatten.select{ |a| a != '.' && a != '..' }