Method: Array.file

Defined in:
lib/rwd/ruby.rb

.file(file) ⇒ Object



491
492
493
494
495
496
497
498
499
500
501
# File 'lib/rwd/ruby.rb', line 491

def self.file(file)
  res = new

  File.open(file) do |f|
    f.readlines.uncomment.chomp.each do |line|
      res << line
    end
  end

  res
end