Sha256: a1fb2db1a93b6131de9c8fe18d28fff209d7a8779fd56de2526a732c387093aa

Contents?: true

Size: 195 Bytes

Versions: 2

Compression:

Stored size: 195 Bytes

Contents

require 'uri'
require 'open-uri'

module FeCoreExt::CoreExt
end

module URI
  def download(file)
    binary = OpenURI.open_uri(self).read
    File.open(file, 'wb') {|f| f.write(binary)}
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
fe_core_ext-0.3.0 lib/fe_core_ext/core_ext/uri.rb
fe_core_ext-0.2.2 lib/fe_core_ext/core_ext/uri.rb