spud_photos 0.9.2 → 0.9.3
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/README.markdown +3 -2
- data/app/models/spud_photo.rb +1 -0
- data/lib/spud_photos/configuration.rb +2 -1
- data/lib/spud_photos/version.rb +1 -1
- metadata +5 -5
data/README.markdown
CHANGED
@@ -18,7 +18,7 @@ Spud Photos is an engine for creating and managing photo galleries, designed for
|
|
18
18
|
|
19
19
|
## Configuration
|
20
20
|
|
21
|
-
Spud Photos accepts the following configuration options
|
21
|
+
Spud Photos accepts the following configuration options. Place them in `application.rb` or in an initializer.
|
22
22
|
|
23
23
|
Spud::Photos.configure do |config|
|
24
24
|
config.base_layout = 'application'
|
@@ -34,6 +34,7 @@ Spud Photos accepts the following configuration options:
|
|
34
34
|
config.s3_credentials = "#{Rails.root}/config/s3.yml"
|
35
35
|
config.storage_path = ":rails_root/public/system/spud_photos/:id/:style/:basename.:extension"
|
36
36
|
config.storage_url = "/system/spud_photos/:id/:style/:basename.:extension"
|
37
|
+
config.s3_host_name = "s3.amazonaws.com" #Defaults to us east zone, change for other regions.
|
37
38
|
end
|
38
39
|
|
39
40
|
The `photo_styles` option will be passed to [Paperclip][2], so any valid paperclip styles can be added here.
|
@@ -72,4 +73,4 @@ Spud uses RSpec for testing. Get the tests running with a few short commands:
|
|
72
73
|
|
73
74
|
rspec spec
|
74
75
|
|
75
|
-
After the tests have completed the current code coverage stats is available by opening ```/coverage/index.html``` in a browser.
|
76
|
+
After the tests have completed the current code coverage stats is available by opening ```/coverage/index.html``` in a browser.
|
data/app/models/spud_photo.rb
CHANGED
@@ -12,6 +12,7 @@ class SpudPhoto < ActiveRecord::Base
|
|
12
12
|
:convert_options => Spud::Photos.config.convert_options,
|
13
13
|
:storage => Spud::Photos.paperclip_storage,
|
14
14
|
:s3_credentials => Spud::Photos.s3_credentials,
|
15
|
+
:s3_host_name => Spud::Photos.s3_host_name,
|
15
16
|
:url => Spud::Photos.storage_url,
|
16
17
|
:path => Spud::Photos.storage_path
|
17
18
|
|
@@ -1,7 +1,7 @@
|
|
1
1
|
module Spud
|
2
2
|
module Photos
|
3
3
|
include ActiveSupport::Configurable
|
4
|
-
config_accessor :photo_styles, :convert_options, :galleries_enabled, :base_layout, :base_path,:s3_credentials,:storage_path,:storage_url,:paperclip_storage, :enable_full_page_caching, :page_caches_to_sweep
|
4
|
+
config_accessor :photo_styles, :convert_options, :galleries_enabled, :base_layout, :base_path,:s3_credentials,:storage_path,:storage_url,:paperclip_storage, :enable_full_page_caching, :page_caches_to_sweep, :s3_host_name
|
5
5
|
self.photo_styles = {
|
6
6
|
:small => '50x50#',
|
7
7
|
:medium => '200x200#',
|
@@ -13,6 +13,7 @@ module Spud
|
|
13
13
|
self.base_path = 'photos'
|
14
14
|
self.paperclip_storage = :filesystem
|
15
15
|
self.s3_credentials = "#{Rails.root}/config/s3.yml"
|
16
|
+
self.s3_host_name = 's3.amazonaws.com'
|
16
17
|
self.storage_path = ":rails_root/public/system/spud_photos/:id/:style/:basename.:extension"
|
17
18
|
self.storage_url = "/system/spud_photos/:id/:style/:basename.:extension"
|
18
19
|
self.enable_full_page_caching = false
|
data/lib/spud_photos/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: spud_photos
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.3
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-
|
12
|
+
date: 2013-07-14 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|
@@ -276,7 +276,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
276
276
|
version: '0'
|
277
277
|
segments:
|
278
278
|
- 0
|
279
|
-
hash: -
|
279
|
+
hash: -4288927536623490343
|
280
280
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
281
281
|
none: false
|
282
282
|
requirements:
|
@@ -285,10 +285,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
285
285
|
version: '0'
|
286
286
|
segments:
|
287
287
|
- 0
|
288
|
-
hash: -
|
288
|
+
hash: -4288927536623490343
|
289
289
|
requirements: []
|
290
290
|
rubyforge_project:
|
291
|
-
rubygems_version: 1.8.
|
291
|
+
rubygems_version: 1.8.25
|
292
292
|
signing_key:
|
293
293
|
specification_version: 3
|
294
294
|
summary: Spud Photos Engine
|