Sha256: 151f8fa38f548208d7559e37d1878238cb3c991e405925d6bc6a67426af2fbc9

Contents?: true

Size: 1.19 KB

Versions: 1

Compression:

Stored size: 1.19 KB

Contents

require "bundler/gem_tasks"

scripts = {
  "https://github.com/jeremyruppel/underscore.inflection" => "https://raw.github.com/jeremyruppel/underscore.inflection/master/src/underscore.inflection.js",
  "https://github.com/epeli/underscore.string" => "https://raw.github.com/epeli/underscore.string/master/lib/underscore.string.js",
  "https://github.com/timrwood/moment/" => "https://raw.github.com/timrwood/moment/master/moment.js",
  "http://josscrowcroft.github.com/accounting.js/" => "https://raw.github.com/josscrowcroft/accounting.js/master/accounting.js",
  "https://github.com/PaulUithol/Backbone-relational" => "https://raw.github.com/PaulUithol/Backbone-relational/master/backbone-relational.js",
  "https://github.com/theironcook/Backbone.ModelBinder" => "https://raw.github.com/theironcook/Backbone.ModelBinder/master/Backbone.ModelBinder.js"
}

require 'open-uri'
desc "Update scripts"
task :update_scripts do
  dir = File.expand_path("../vendor/assets/javascripts/chiropractor", __FILE__)
  FileUtils.mkdir_p(dir)
  scripts.each do |repo_url, file_url|
    file = File.basename(URI.parse(file_url).path)
    output = File.join(dir,file)
    File.open(output, "w+"){|f| f.write(open(file_url).read)}
  end  
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
chiropractor-1.0.0 Rakefile