cacheable_flash 0.2.1 → 0.2.2
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGES +4 -0
- data/README.rdoc +12 -6
- data/VERSION +1 -1
- data/cacheable_flash.gemspec +1 -1
- data/lib/generators/cacheable_flash/install/install_generator.rb +3 -4
- metadata +20 -20
data/CHANGES
CHANGED
data/README.rdoc
CHANGED
@@ -22,17 +22,23 @@ gem 'cacheable_flash'
|
|
22
22
|
|
23
23
|
=== Without asset pipeline, or pre-Rails 3.1:
|
24
24
|
|
25
|
-
|
25
|
+
First copy the JS assets into your app:
|
26
|
+
rails generate cacheable_flash:install
|
26
27
|
|
27
|
-
|
28
|
-
|
28
|
+
CacheableFlash adds its javascript dependencies as a Rails 3 javascript 'expansion',
|
29
|
+
which are only used if you are NOT using the asset pipeline (apparently?).
|
30
|
+
|
31
|
+
So if you have config.assets.enabled = false in application.rb then in your layout:
|
32
|
+
javascript_include_tag :cacheable_flash
|
33
|
+
|
34
|
+
Otherwise, in your layout, just source them like normal:
|
35
|
+
javascript_include_tag 'flash', 'jquery.cookie'
|
29
36
|
|
30
37
|
=== With asset pipeline (requires Rails 3.1)
|
31
38
|
|
32
39
|
The asset pipeline should have access to the assets in this gem via your app/assets/application.js:
|
33
|
-
|
34
|
-
//= require
|
35
|
-
//= require jquery.cookie
|
40
|
+
//= require flash
|
41
|
+
//= require jquery.cookie
|
36
42
|
|
37
43
|
== Description
|
38
44
|
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.2
|
data/cacheable_flash.gemspec
CHANGED
@@ -5,7 +5,7 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = "cacheable_flash"
|
8
|
-
s.version = "0.2.
|
8
|
+
s.version = "0.2.2"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Peter H. Boling", "Brian Takita"]
|
@@ -6,17 +6,16 @@ module CacheableFlash
|
|
6
6
|
# @example
|
7
7
|
# $ rails generate cacheable_flash:install
|
8
8
|
#
|
9
|
-
# @todo Test with Rails 3.0
|
10
9
|
class InstallGenerator < Rails::Generators::Base
|
11
10
|
source_root File.expand_path('../../../../../vendor/assets/javascripts/', __FILE__)
|
12
11
|
|
13
12
|
# Rails 3.1 has the asset pipeline, no need to copy javascript files anymore
|
14
13
|
# Rails 3.0 doesn't have an asset pipeline, so we copy in javascript files
|
15
|
-
if ::Rails::VERSION::MAJOR == 3 && ::Rails::VERSION::MINOR == 1
|
16
|
-
ActiveSupport::Deprecation.warn("Rails 3.1 has the asset pipeline, so you only need to copy javascript files if you aren't using it.")
|
17
|
-
end
|
18
14
|
desc "Copies some JS files to public/javascripts/"
|
19
15
|
def copy_files
|
16
|
+
if ::Rails::VERSION::MAJOR == 3 && ::Rails::VERSION::MINOR == 1
|
17
|
+
ActiveSupport::Deprecation.warn("Rails 3.1 has the asset pipeline, so you only need to copy javascript files if you aren't using it.")
|
18
|
+
end
|
20
19
|
template 'flash.js', 'public/javascripts/flash.js'
|
21
20
|
template 'jquery.cookie.js', 'public/javascripts/jquery.cookie.js'
|
22
21
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cacheable_flash
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.2
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -14,7 +14,7 @@ date: 2011-09-10 00:00:00.000000000Z
|
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: activesupport
|
17
|
-
requirement: &
|
17
|
+
requirement: &70264552596200 !ruby/object:Gem::Requirement
|
18
18
|
none: false
|
19
19
|
requirements:
|
20
20
|
- - ! '>='
|
@@ -22,10 +22,10 @@ dependencies:
|
|
22
22
|
version: '0'
|
23
23
|
type: :runtime
|
24
24
|
prerelease: false
|
25
|
-
version_requirements: *
|
25
|
+
version_requirements: *70264552596200
|
26
26
|
- !ruby/object:Gem::Dependency
|
27
27
|
name: actionpack
|
28
|
-
requirement: &
|
28
|
+
requirement: &70264552595700 !ruby/object:Gem::Requirement
|
29
29
|
none: false
|
30
30
|
requirements:
|
31
31
|
- - ! '>='
|
@@ -33,10 +33,10 @@ dependencies:
|
|
33
33
|
version: '0'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
|
-
version_requirements: *
|
36
|
+
version_requirements: *70264552595700
|
37
37
|
- !ruby/object:Gem::Dependency
|
38
38
|
name: json
|
39
|
-
requirement: &
|
39
|
+
requirement: &70264552595160 !ruby/object:Gem::Requirement
|
40
40
|
none: false
|
41
41
|
requirements:
|
42
42
|
- - ! '>='
|
@@ -44,10 +44,10 @@ dependencies:
|
|
44
44
|
version: '0'
|
45
45
|
type: :runtime
|
46
46
|
prerelease: false
|
47
|
-
version_requirements: *
|
47
|
+
version_requirements: *70264552595160
|
48
48
|
- !ruby/object:Gem::Dependency
|
49
49
|
name: rspec
|
50
|
-
requirement: &
|
50
|
+
requirement: &70264552594640 !ruby/object:Gem::Requirement
|
51
51
|
none: false
|
52
52
|
requirements:
|
53
53
|
- - ~>
|
@@ -55,10 +55,10 @@ dependencies:
|
|
55
55
|
version: 2.3.0
|
56
56
|
type: :development
|
57
57
|
prerelease: false
|
58
|
-
version_requirements: *
|
58
|
+
version_requirements: *70264552594640
|
59
59
|
- !ruby/object:Gem::Dependency
|
60
60
|
name: yard
|
61
|
-
requirement: &
|
61
|
+
requirement: &70264552594020 !ruby/object:Gem::Requirement
|
62
62
|
none: false
|
63
63
|
requirements:
|
64
64
|
- - ~>
|
@@ -66,10 +66,10 @@ dependencies:
|
|
66
66
|
version: 0.6.0
|
67
67
|
type: :development
|
68
68
|
prerelease: false
|
69
|
-
version_requirements: *
|
69
|
+
version_requirements: *70264552594020
|
70
70
|
- !ruby/object:Gem::Dependency
|
71
71
|
name: bundler
|
72
|
-
requirement: &
|
72
|
+
requirement: &70264552541140 !ruby/object:Gem::Requirement
|
73
73
|
none: false
|
74
74
|
requirements:
|
75
75
|
- - ~>
|
@@ -77,10 +77,10 @@ dependencies:
|
|
77
77
|
version: 1.0.0
|
78
78
|
type: :development
|
79
79
|
prerelease: false
|
80
|
-
version_requirements: *
|
80
|
+
version_requirements: *70264552541140
|
81
81
|
- !ruby/object:Gem::Dependency
|
82
82
|
name: jeweler
|
83
|
-
requirement: &
|
83
|
+
requirement: &70264552540540 !ruby/object:Gem::Requirement
|
84
84
|
none: false
|
85
85
|
requirements:
|
86
86
|
- - ~>
|
@@ -88,10 +88,10 @@ dependencies:
|
|
88
88
|
version: 1.6.4
|
89
89
|
type: :development
|
90
90
|
prerelease: false
|
91
|
-
version_requirements: *
|
91
|
+
version_requirements: *70264552540540
|
92
92
|
- !ruby/object:Gem::Dependency
|
93
93
|
name: reek
|
94
|
-
requirement: &
|
94
|
+
requirement: &70264552539940 !ruby/object:Gem::Requirement
|
95
95
|
none: false
|
96
96
|
requirements:
|
97
97
|
- - ~>
|
@@ -99,10 +99,10 @@ dependencies:
|
|
99
99
|
version: 1.2.8
|
100
100
|
type: :development
|
101
101
|
prerelease: false
|
102
|
-
version_requirements: *
|
102
|
+
version_requirements: *70264552539940
|
103
103
|
- !ruby/object:Gem::Dependency
|
104
104
|
name: roodi
|
105
|
-
requirement: &
|
105
|
+
requirement: &70264552539320 !ruby/object:Gem::Requirement
|
106
106
|
none: false
|
107
107
|
requirements:
|
108
108
|
- - ~>
|
@@ -110,7 +110,7 @@ dependencies:
|
|
110
110
|
version: 2.1.0
|
111
111
|
type: :development
|
112
112
|
prerelease: false
|
113
|
-
version_requirements: *
|
113
|
+
version_requirements: *70264552539320
|
114
114
|
description: ! 'This plugin enables greater levels of page caching by rendering flash
|
115
115
|
|
116
116
|
messages from a cookie using JavaScript, instead of in your Rails
|
@@ -165,7 +165,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
165
165
|
version: '0'
|
166
166
|
segments:
|
167
167
|
- 0
|
168
|
-
hash:
|
168
|
+
hash: 952371363782069645
|
169
169
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
170
170
|
none: false
|
171
171
|
requirements:
|