Module: Monkey::Ext::File::ExtClassMethods

Defined in:
lib/monkey/ext/file.rb

Instance Method Summary collapse

Instance Method Details

#write(path, content = '', mode = 'w') ⇒ Object



5
6
7
8
# File 'lib/monkey/ext/file.rb', line 5

def write(path, content = '', mode = 'w')
  File.open(path, mode) { |f| f.write content }
  content
end