ratnikov-ajax_resource 0.01 → 0.02

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. data/tasks/ajax_resource.rb +14 -5
  2. metadata +13 -4
@@ -3,11 +3,20 @@ namespace :ajax_resource do
3
3
  namespace :rails do
4
4
  desc "Installs ajax_resource javascript in the public/javascripts directory. Set COMPRESS=true to install the compressed version."
5
5
  task :install do
6
- extension = ENV["COMPRESS"] == "true" ? "min" : "src"
7
- from = File.join File.dirname(__FILE__), '..', 'build', "ajax_resource-#{extension}.js"
8
- to = File.join Rails.root, 'public', 'javascripts', 'ajax_resource.js'
9
- FileUtils.cp(from, to, :verbose => true);
10
- puts "Done installing."
6
+ require 'jake'
7
+
8
+ build = Jake::Build.new File.join(File.dirname(__FILE__), '..')
9
+
10
+ class << build
11
+ def build_directory
12
+ File.join Rails.root, 'public', 'javascripts'
13
+ end
14
+ end
15
+
16
+ build.force!
17
+ build.run!
18
+
19
+ puts "Installed to #{build.build_directory}"
11
20
  end
12
21
  end
13
22
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ratnikov-ajax_resource
3
3
  version: !ruby/object:Gem::Version
4
- version: "0.01"
4
+ version: "0.02"
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dmitry Ratnikov
@@ -9,10 +9,19 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2009-02-18 00:00:00 -08:00
12
+ date: 2009-02-23 00:00:00 -08:00
13
13
  default_executable:
14
- dependencies: []
15
-
14
+ dependencies:
15
+ - !ruby/object:Gem::Dependency
16
+ name: jake
17
+ type: :runtime
18
+ version_requirement:
19
+ version_requirements: !ruby/object:Gem::Requirement
20
+ requirements:
21
+ - - ">="
22
+ - !ruby/object:Gem::Version
23
+ version: "0"
24
+ version:
16
25
  description:
17
26
  email: dmitryr@webitects.com
18
27
  executables: []