cloud_crooner 0.0.3 → 0.0.4

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 533f793c3642efdcd932c69ea38c14b294292435
4
- data.tar.gz: a5e7391023ab13648bb09b18456d4005ddd6b902
3
+ metadata.gz: 4bfc2bd64853b8882225c1eee53f60db46ba204f
4
+ data.tar.gz: 48911144f0e9b22e4151f68faa751958c11e1bef
5
5
  SHA512:
6
- metadata.gz: 3ce43f58924705bf3479a4d7b77746b082b7fc49044e50bf8b455d08648a23b84baf11a78627b59d0fef733c0c5a71225d9374dab49cfd6f9a2e0aabf9876399
7
- data.tar.gz: 32c3c5c46cac86393ceccf6c9a3198b7aae8a9ae0ebe5f42ecb7ccb0380dd996475e4b0804c0256993e271729e1a27925b7b0c2cd49fa333581e7a0a6080bc27
6
+ metadata.gz: 71598ab117b33123982bbbc3716f272af829aec6ec992504855cfcd44769c19e12483ebceed603261ef2b851b843c0fae4744cf057c2b148d63203b129a454cd
7
+ data.tar.gz: 74b5d266070262eb66919df7eb2b80dbe2fef29939b636aed71fd5ecc07af9f50452cd3467e047b914b47d8af611073bbf0d747c1df324fc4239935cec25fbe3
@@ -1,3 +1,6 @@
1
+ # v0.0.4
2
+ * Updated fog dependency to work with ruby 2.1.1
3
+
1
4
  # v0.0.3
2
5
  Features:
3
6
  * Removed `remote_assets` option, replaced with `serve_assets` which allows for
data/README.md CHANGED
@@ -26,9 +26,13 @@ Cloud Crooner has many configuration options which can be set in a configure blo
26
26
  config.prefix = '/assets'
27
27
  end
28
28
 
29
- `remote_enabled` - true by default. When disabled, your assets will be served from your public folder instead of from S3. Only works in production. _Be aware that attempting to test this on your machine using rackup or thin will not work_. Rack does not serve files from `/public`. If you want to see static assets in action without messing with Rack internals, you must run [shotgun](https://github.com/rtomayko/shotgun) or something like it.
29
+ `serve_assets` - where and how to serve assets. You have three options:
30
30
 
31
- `public_folder` - the public folder of your application. By default set to `/public`. If you are using a different public folder, you must set it here as well as in your application.
31
+ * `local_dynamic` - default in test & dev environments. Serves assets locally with Sprockets, dynamically generating them.
32
+ * `local_static` - serves compiled assets from `public_folder`. _Be aware that attempting to test this on your machine using rackup or thin will not work_. Rack does not serve files from `\public`. If you want to see static assets in action without messing with Rack internals, you must run [shotgun](https://github.com/rtomayko/shotgun) or something like it.
33
+ * `remote` - default in prod - serves compiled assets from S3
34
+
35
+ `public_folder` - the public folder of your application. By default set to `/public`. If you are using a different public folder, you must set it in this config block as well as in your application.
32
36
 
33
37
  `prefix` - the path from root where you keep your assets. By default it is `/assets`. Your compiled assets will be placed in `public_folder/prefix.` It will also be the pseudo-folder on S3 where your assets will be stored, so the paths will look something like `http://bucket-name.s3.amazonaws.com/prefix/filename`.
34
38
 
@@ -134,9 +138,9 @@ Now on the command line, run `rake assets:sync` and the following will happen:
134
138
  3. manifest will be updated
135
139
  4. old backups locally and remotely will be deleted
136
140
 
137
- Running your app in development mode will serve uncompiled assets locally (from `/assets`), and running your app in production mode will serve your compiled assets from S3. If you have `remote_assets` set to `false` and are in production mode, your compiled assets will be served from `public/assets`.
141
+ Running your app in development mode will serve uncompiled assets locally (from `/assets`), and running your app in production mode will serve your compiled assets from S3. If you have `serve_assets` set to `local_static` your compiled assets will be served from `public/assets`.
138
142
 
139
- If you want to precompile and upload your assets every time you spin up your app, you can put the configure block directly into config.ru and after config run CloudCrooner.sync.
143
+ If you want to precompile and upload your assets every time you spin up your app, you can put the configure block directly into config.ru and after config run `CloudCrooner.sync`.
140
144
 
141
145
 
142
146
  ## Helpers
@@ -144,17 +148,25 @@ If you want to precompile and upload your assets every time you spin up your app
144
148
  Helper methods are provided for use in your views using the [sprockets-helpers](https://github.com/petebrowne/sprockets-helpers) gem.
145
149
 
146
150
  `stylesheet_tag` - put this in your views to insert an html tag referencing a stylesheet in the Sprockets load path. For example, if you have `/assets/stylesheets/application.scss` and have placed `assets/stylesheets` in the load path, you would write:
151
+
147
152
  <%= stylesheet_tag 'application' %>
153
+
148
154
  and in dev it will compile to
155
+
149
156
  <link rel="stylesheet" href="/assets/application.css">
157
+
150
158
  in prod it will compile to
159
+
151
160
  <link rel="stylesheet" href="http://my-bucket.s3.amazonaws.com/assets/application.css">
152
161
 
153
162
  `javascript_tag` - similar to `stylesheet_tag`
154
163
 
155
164
  `asset_tag` - similar to stylesheet, but you pass a block to generate a tag of your choosing.
165
+
156
166
  asset_tag('main.js') { |path| "<script src=#{path}></script>" }
167
+
157
168
  will generate
169
+
158
170
  <script src=/main.js></script>
159
171
 
160
172
  `asset_path` - returns the path to an asset, no tag.
@@ -25,6 +25,6 @@ Gem::Specification.new do |spec|
25
25
  spec.add_development_dependency "test-construct"
26
26
 
27
27
  spec.add_dependency "sprockets", "~>2.10"
28
- spec.add_dependency "fog", "~> 1.12"
28
+ spec.add_dependency "fog", "~> 1.2"
29
29
  spec.add_dependency "sprockets-helpers"
30
30
  end
@@ -1,3 +1,3 @@
1
1
  module CloudCrooner
2
- VERSION = "0.0.3"
2
+ VERSION = "0.0.4"
3
3
  end
@@ -356,7 +356,7 @@ describe CloudCrooner do
356
356
  end # construct
357
357
  end # it
358
358
 
359
- it 'compiles and does not sync assets if remote_enabled is false' do
359
+ it 'compiles and does not sync assets if serving local files' do
360
360
  within_construct do |c|
361
361
  mock_environment(c)
362
362
  CloudCrooner.configure do |config|
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cloud_crooner
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - bambery
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-08-25 00:00:00.000000000 Z
11
+ date: 2014-03-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -100,14 +100,14 @@ dependencies:
100
100
  requirements:
101
101
  - - ~>
102
102
  - !ruby/object:Gem::Version
103
- version: '1.12'
103
+ version: '1.2'
104
104
  type: :runtime
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
108
  - - ~>
109
109
  - !ruby/object:Gem::Version
110
- version: '1.12'
110
+ version: '1.2'
111
111
  - !ruby/object:Gem::Dependency
112
112
  name: sprockets-helpers
113
113
  requirement: !ruby/object:Gem::Requirement