7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
# File 'lib/ajax-chosen-rails/source_file.rb', line 7
def fetch
self.destination_root = "vendor/assets"
remote = "https://github.com/fatfreecrm/ajax-chosen"
branch = "master"
get "#{remote}/raw/#{branch}/src/ajax-chosen.jquery.coffee", "javascripts/ajax-chosen.jquery.coffee"
get "#{remote}/raw/#{branch}/src/ajax-chosen.proto.coffee", "javascripts/ajax-chosen.proto.coffee"
get "#{remote}/raw/#{branch}/VERSION", "VERSION"
inside destination_root do
version = File.read("VERSION").sub("\n", "")
gsub_file "../../lib/ajax-chosen-rails/version.rb", /VERSION\s=\s"(\d|\.)+"$/ do |match|
%Q{VERSION = "#{version}"}
end
end
end
|