jammit-s3 0.5.4.3 → 0.6.0.1
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.
- data/jammit-s3.gemspec +1 -1
- data/lib/jammit-s3.rb +0 -27
- data/lib/jammit/s3_uploader.rb +1 -1
- metadata +6 -23
data/jammit-s3.gemspec
CHANGED
data/lib/jammit-s3.rb
CHANGED
@@ -7,30 +7,3 @@ module Jammit
|
|
7
7
|
S3Uploader.new(options).upload
|
8
8
|
end
|
9
9
|
end
|
10
|
-
|
11
|
-
if defined?(Rails)
|
12
|
-
module Jammit
|
13
|
-
class JammitRailtie < Rails::Railtie
|
14
|
-
initializer "set asset host and asset id" do
|
15
|
-
config.after_initialize do
|
16
|
-
if Jammit.configuration[:use_cloudfront] && Jammit.configuration[:cloudfront_domain].present?
|
17
|
-
asset_hostname = Jammit.configuration[:cloudfront_domain]
|
18
|
-
else
|
19
|
-
asset_hostname = "#{Jammit.configuration[:s3_bucket]}.s3.amazonaws.com"
|
20
|
-
end
|
21
|
-
|
22
|
-
if Jammit.package_assets and asset_hostname.present?
|
23
|
-
ActionController::Base.asset_host = Proc.new do |source, request|
|
24
|
-
if Jammit.configuration.has_key?(:ssl)
|
25
|
-
protocol = Jammit.configuration[:ssl] ? "https://" : "http://"
|
26
|
-
else
|
27
|
-
protocol = request.protocol
|
28
|
-
end
|
29
|
-
"#{protocol}#{asset_hostname}"
|
30
|
-
end
|
31
|
-
end
|
32
|
-
end
|
33
|
-
end
|
34
|
-
end
|
35
|
-
end
|
36
|
-
end
|
data/lib/jammit/s3_uploader.rb
CHANGED
@@ -29,7 +29,7 @@ module Jammit
|
|
29
29
|
end
|
30
30
|
|
31
31
|
# add images
|
32
|
-
globs << "public/images/**/*"
|
32
|
+
globs << "public/images/**/*" unless Jammit.configuration[:s3_upload_images] == false
|
33
33
|
|
34
34
|
# add custom configuration if defined
|
35
35
|
s3_upload_files = Jammit.configuration[:s3_upload_files]
|
metadata
CHANGED
@@ -1,13 +1,8 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jammit-s3
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
prerelease:
|
5
|
-
|
6
|
-
- 0
|
7
|
-
- 5
|
8
|
-
- 4
|
9
|
-
- 3
|
10
|
-
version: 0.5.4.3
|
4
|
+
prerelease:
|
5
|
+
version: 0.6.0.1
|
11
6
|
platform: ruby
|
12
7
|
authors:
|
13
8
|
- Jacques Crocker
|
@@ -15,7 +10,7 @@ autorequire:
|
|
15
10
|
bindir: bin
|
16
11
|
cert_chain: []
|
17
12
|
|
18
|
-
date:
|
13
|
+
date: 2011-03-12 00:00:00 -08:00
|
19
14
|
default_executable:
|
20
15
|
dependencies:
|
21
16
|
- !ruby/object:Gem::Dependency
|
@@ -25,10 +20,6 @@ dependencies:
|
|
25
20
|
requirements:
|
26
21
|
- - ">="
|
27
22
|
- !ruby/object:Gem::Version
|
28
|
-
segments:
|
29
|
-
- 0
|
30
|
-
- 5
|
31
|
-
- 4
|
32
23
|
version: 0.5.4
|
33
24
|
type: :runtime
|
34
25
|
prerelease: false
|
@@ -40,10 +31,6 @@ dependencies:
|
|
40
31
|
requirements:
|
41
32
|
- - ">="
|
42
33
|
- !ruby/object:Gem::Version
|
43
|
-
segments:
|
44
|
-
- 0
|
45
|
-
- 1
|
46
|
-
- 7
|
47
34
|
version: 0.1.7
|
48
35
|
type: :runtime
|
49
36
|
prerelease: false
|
@@ -55,10 +42,6 @@ dependencies:
|
|
55
42
|
requirements:
|
56
43
|
- - ">="
|
57
44
|
- !ruby/object:Gem::Version
|
58
|
-
segments:
|
59
|
-
- 0
|
60
|
-
- 3
|
61
|
-
- 7
|
62
45
|
version: 0.3.7
|
63
46
|
type: :runtime
|
64
47
|
prerelease: false
|
@@ -92,7 +75,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
92
75
|
requirements:
|
93
76
|
- - ">="
|
94
77
|
- !ruby/object:Gem::Version
|
95
|
-
hash:
|
78
|
+
hash: 2557465707510469440
|
96
79
|
segments:
|
97
80
|
- 0
|
98
81
|
version: "0"
|
@@ -101,14 +84,14 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
101
84
|
requirements:
|
102
85
|
- - ">="
|
103
86
|
- !ruby/object:Gem::Version
|
104
|
-
hash:
|
87
|
+
hash: 2557465707510469440
|
105
88
|
segments:
|
106
89
|
- 0
|
107
90
|
version: "0"
|
108
91
|
requirements: []
|
109
92
|
|
110
93
|
rubyforge_project: jammit-s3
|
111
|
-
rubygems_version: 1.
|
94
|
+
rubygems_version: 1.5.2
|
112
95
|
signing_key:
|
113
96
|
specification_version: 3
|
114
97
|
summary: Asset Packaging for Rails with Deployment to S3/Cloudfront
|