Class: FileSystem

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

Instance Method Summary collapse

Instance Method Details

#read_expand(expandable_path) ⇒ Object



117
118
119
# File 'lib/subdl.rb', line 117

def read_expand expandable_path
  File.read(File.expand_path(expandable_path))
end

#save_file(filename, contents) ⇒ Object



112
113
114
115
116
# File 'lib/subdl.rb', line 112

def save_file filename, contents
  File.open filename, 'w' do |f|
    f.write contents
  end
end