paperclip-s3 1.0.0 → 1.1.0
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/paperclip-s3/railtie.rb +11 -6
- data/lib/paperclip-s3/version.rb +1 -1
- data/paperclip-s3.gemspec +4 -2
- metadata +56 -47
data/lib/paperclip-s3/railtie.rb
CHANGED
@@ -7,17 +7,22 @@ module Paperclip
|
|
7
7
|
ActiveSupport.on_load :active_record do
|
8
8
|
Paperclip::S3::Railtie.insert
|
9
9
|
end
|
10
|
-
end
|
10
|
+
end
|
11
11
|
end
|
12
12
|
end
|
13
13
|
|
14
14
|
class Railtie
|
15
15
|
def self.insert
|
16
|
-
|
17
|
-
|
18
|
-
|
16
|
+
in_production = false
|
17
|
+
|
18
|
+
if (defined?(Rails.env) && Rails.env)
|
19
|
+
in_production = Rails.env.production?
|
20
|
+
elsif (defined?(RAILS_ENV) && RAILS_ENV)
|
21
|
+
in_production = RAILS_ENV =~ /production/
|
19
22
|
end
|
20
|
-
|
23
|
+
|
24
|
+
ActiveRecord::Base.send(:include, Paperclip::S3::Glue) if in_production
|
25
|
+
end
|
21
26
|
end
|
22
27
|
end
|
23
|
-
end
|
28
|
+
end
|
data/lib/paperclip-s3/version.rb
CHANGED
data/paperclip-s3.gemspec
CHANGED
@@ -13,9 +13,11 @@ Gem::Specification.new do |s|
|
|
13
13
|
|
14
14
|
s.rubyforge_project = "paperclip-s3"
|
15
15
|
|
16
|
-
s.add_dependency('paperclip', '~> 2.
|
16
|
+
s.add_dependency('paperclip', '~> 2.4')
|
17
17
|
s.add_dependency('aws-s3', '~> 0.6.2')
|
18
|
-
|
18
|
+
|
19
|
+
s.add_development_dependency('rake', '~> 0.9.2')
|
20
|
+
|
19
21
|
s.files = `git ls-files`.split("\n")
|
20
22
|
s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
|
21
23
|
s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
|
metadata
CHANGED
@@ -1,50 +1,57 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: paperclip-s3
|
3
|
-
version: !ruby/object:Gem::Version
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 1.1.0
|
4
5
|
prerelease:
|
5
|
-
version: 1.0.0
|
6
6
|
platform: ruby
|
7
|
-
authors:
|
8
|
-
-
|
7
|
+
authors:
|
8
|
+
- Nicolás Hock Isaza
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
dependencies:
|
16
|
-
- !ruby/object:Gem::Dependency
|
12
|
+
date: 2011-12-02 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
17
15
|
name: paperclip
|
18
|
-
|
19
|
-
requirement: &id001 !ruby/object:Gem::Requirement
|
16
|
+
requirement: &70268317306300 !ruby/object:Gem::Requirement
|
20
17
|
none: false
|
21
|
-
requirements:
|
18
|
+
requirements:
|
22
19
|
- - ~>
|
23
|
-
- !ruby/object:Gem::Version
|
24
|
-
version: 2.
|
20
|
+
- !ruby/object:Gem::Version
|
21
|
+
version: '2.4'
|
25
22
|
type: :runtime
|
26
|
-
version_requirements: *id001
|
27
|
-
- !ruby/object:Gem::Dependency
|
28
|
-
name: aws-s3
|
29
23
|
prerelease: false
|
30
|
-
|
24
|
+
version_requirements: *70268317306300
|
25
|
+
- !ruby/object:Gem::Dependency
|
26
|
+
name: aws-s3
|
27
|
+
requirement: &70268317305160 !ruby/object:Gem::Requirement
|
31
28
|
none: false
|
32
|
-
requirements:
|
29
|
+
requirements:
|
33
30
|
- - ~>
|
34
|
-
- !ruby/object:Gem::Version
|
31
|
+
- !ruby/object:Gem::Version
|
35
32
|
version: 0.6.2
|
36
33
|
type: :runtime
|
37
|
-
|
38
|
-
|
39
|
-
|
34
|
+
prerelease: false
|
35
|
+
version_requirements: *70268317305160
|
36
|
+
- !ruby/object:Gem::Dependency
|
37
|
+
name: rake
|
38
|
+
requirement: &70268317304360 !ruby/object:Gem::Requirement
|
39
|
+
none: false
|
40
|
+
requirements:
|
41
|
+
- - ~>
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
version: 0.9.2
|
44
|
+
type: :development
|
45
|
+
prerelease: false
|
46
|
+
version_requirements: *70268317304360
|
47
|
+
description: The gem will simply extend the has_attached_file to make it store on
|
48
|
+
Amazon S3 when the application is on production. Great for Heroku applications.
|
49
|
+
email:
|
40
50
|
- nhocki@gmail.com
|
41
51
|
executables: []
|
42
|
-
|
43
52
|
extensions: []
|
44
|
-
|
45
53
|
extra_rdoc_files: []
|
46
|
-
|
47
|
-
files:
|
54
|
+
files:
|
48
55
|
- .gitignore
|
49
56
|
- Gemfile
|
50
57
|
- README.textile
|
@@ -55,33 +62,35 @@ files:
|
|
55
62
|
- lib/paperclip-s3/version.rb
|
56
63
|
- paperclip-s3.gemspec
|
57
64
|
- rails/init.rb
|
58
|
-
|
59
|
-
homepage: ""
|
65
|
+
homepage: ''
|
60
66
|
licenses: []
|
61
|
-
|
62
67
|
post_install_message:
|
63
68
|
rdoc_options: []
|
64
|
-
|
65
|
-
require_paths:
|
69
|
+
require_paths:
|
66
70
|
- lib
|
67
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
71
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
68
72
|
none: false
|
69
|
-
requirements:
|
70
|
-
- -
|
71
|
-
- !ruby/object:Gem::Version
|
72
|
-
version:
|
73
|
-
|
73
|
+
requirements:
|
74
|
+
- - ! '>='
|
75
|
+
- !ruby/object:Gem::Version
|
76
|
+
version: '0'
|
77
|
+
segments:
|
78
|
+
- 0
|
79
|
+
hash: -2305815320097256849
|
80
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
74
81
|
none: false
|
75
|
-
requirements:
|
76
|
-
- -
|
77
|
-
- !ruby/object:Gem::Version
|
78
|
-
version:
|
82
|
+
requirements:
|
83
|
+
- - ! '>='
|
84
|
+
- !ruby/object:Gem::Version
|
85
|
+
version: '0'
|
86
|
+
segments:
|
87
|
+
- 0
|
88
|
+
hash: -2305815320097256849
|
79
89
|
requirements: []
|
80
|
-
|
81
90
|
rubyforge_project: paperclip-s3
|
82
|
-
rubygems_version: 1.
|
91
|
+
rubygems_version: 1.8.10
|
83
92
|
signing_key:
|
84
93
|
specification_version: 3
|
85
|
-
summary: Simple gem that makes paperclip save the attachments on Amazon S3 for a production
|
94
|
+
summary: Simple gem that makes paperclip save the attachments on Amazon S3 for a production
|
95
|
+
Rails application.
|
86
96
|
test_files: []
|
87
|
-
|