Class: Collect

Inherits:
Object
  • Object
show all
Defined in:
lib/ripli.rb

Instance Method Summary collapse

Instance Method Details

#list(*proxy) ⇒ Object



6
7
8
9
10
11
# File 'lib/ripli.rb', line 6

def list(*proxy)
  proxy.each { |type| @list = ""
  Dir.glob(File.join('**', "#{type}.txt")).each { |file|
  File.readlines(file).each { |line| @list << line; puts line }
  File.write("log/#{type}.list", "#{@list}") } }
end