Sha256: 6c8438b7d51ac3fd3449d78401b145625672f6c88f964c85e88c7edf7a7a7099

Contents?: true

Size: 640 Bytes

Versions: 1

Compression:

Stored size: 640 Bytes

Contents

module Kango
  def self.install!
    zipfile = File.expand_path(File.join("~", 'kango-framework.zip'))
    puts "Downloading Kango Framework to #{zipfile}..."
    require 'open-uri'
    File.open(zipfile, 'wb') do |file|
      open(KANGO_FRAMEWORK_URL, 'rb') do |download|
        file.write download.read
      end
    end
    puts "Download complete! Extracting..."
    `unzip #{zipfile} -d #{KANGO_FRAMEWORK}`
    if Kango.framework_exists?
      FileUtils.rm zipfile
      puts "Kango Framework is ready. You can now rake build"
    else
      puts "Something went wrong... probably could not download Kango Framework"
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
kango-0.0.1.0.9.2 lib/kango/install.rb