crumbs 1.0.8 → 1.0.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/MIT-LICENSE +1 -1
- data/README.rdoc +1 -1
- data/lib/crumbs/action_controller/base.rb +40 -87
- data/lib/crumbs/definitions.rb +26 -0
- data/lib/crumbs/version.rb +1 -1
- data/lib/crumbs.rb +1 -2
- data/test/dummy/app/controllers/pages_controller.rb +1 -1
- data/test/dummy/log/test.log +13928 -0
- data/test/dummy/tmp/cache/assets/test/sprockets/13fe41fee1fe35b49d145bcc06610705 +0 -0
- data/test/dummy/tmp/cache/assets/test/sprockets/2f5173deea6c795b8fdde723bb4b63af +0 -0
- data/test/dummy/tmp/cache/assets/test/sprockets/357970feca3ac29060c1e3861e2c0953 +0 -0
- data/test/dummy/tmp/cache/assets/test/sprockets/cffd775d018f68ce5dba1ee0d951a994 +0 -0
- data/test/dummy/tmp/cache/assets/test/sprockets/d771ace226fc8215a3572e0aa35bb0d6 +0 -0
- data/test/dummy/tmp/cache/assets/test/sprockets/f7cbd26ba1d28d48de824f0e94586655 +0 -0
- data/test/with_last_test.rb +45 -45
- data/test/without_last_test.rb +40 -40
- metadata +20 -20
- data/lib/crumbs/history.rb +0 -34
metadata
CHANGED
@@ -1,58 +1,60 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: crumbs
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
|
-
-
|
7
|
+
- Museways
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2014-03-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
17
|
+
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: 3.0.0
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- -
|
24
|
+
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: 3.0.0
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: sqlite3
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- -
|
31
|
+
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '0'
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- -
|
38
|
+
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
41
|
description: Adds a handy crumbs variable available in your views.
|
42
42
|
email:
|
43
|
-
-
|
43
|
+
- hello@museways.com
|
44
44
|
executables: []
|
45
45
|
extensions: []
|
46
46
|
extra_rdoc_files: []
|
47
47
|
files:
|
48
|
+
- MIT-LICENSE
|
49
|
+
- README.rdoc
|
50
|
+
- Rakefile
|
51
|
+
- lib/crumbs.rb
|
48
52
|
- lib/crumbs/action_controller/base.rb
|
49
|
-
- lib/crumbs/
|
53
|
+
- lib/crumbs/definitions.rb
|
50
54
|
- lib/crumbs/railtie.rb
|
51
55
|
- lib/crumbs/version.rb
|
52
|
-
-
|
53
|
-
-
|
54
|
-
- Rakefile
|
55
|
-
- README.rdoc
|
56
|
+
- test/dummy/README.rdoc
|
57
|
+
- test/dummy/Rakefile
|
56
58
|
- test/dummy/app/assets/javascripts/application.js
|
57
59
|
- test/dummy/app/assets/stylesheets/application.css
|
58
60
|
- test/dummy/app/controllers/application_controller.rb
|
@@ -63,6 +65,7 @@ files:
|
|
63
65
|
- test/dummy/bin/bundle
|
64
66
|
- test/dummy/bin/rails
|
65
67
|
- test/dummy/bin/rake
|
68
|
+
- test/dummy/config.ru
|
66
69
|
- test/dummy/config/application.rb
|
67
70
|
- test/dummy/config/boot.rb
|
68
71
|
- test/dummy/config/database.yml
|
@@ -79,7 +82,6 @@ files:
|
|
79
82
|
- test/dummy/config/initializers/wrap_parameters.rb
|
80
83
|
- test/dummy/config/locales/en.yml
|
81
84
|
- test/dummy/config/routes.rb
|
82
|
-
- test/dummy/config.ru
|
83
85
|
- test/dummy/db/development.sqlite3
|
84
86
|
- test/dummy/db/schema.rb
|
85
87
|
- test/dummy/db/test.sqlite3
|
@@ -89,8 +91,6 @@ files:
|
|
89
91
|
- test/dummy/public/422.html
|
90
92
|
- test/dummy/public/500.html
|
91
93
|
- test/dummy/public/favicon.ico
|
92
|
-
- test/dummy/Rakefile
|
93
|
-
- test/dummy/README.rdoc
|
94
94
|
- test/dummy/tmp/cache/assets/test/sprockets/13fe41fee1fe35b49d145bcc06610705
|
95
95
|
- test/dummy/tmp/cache/assets/test/sprockets/2f5173deea6c795b8fdde723bb4b63af
|
96
96
|
- test/dummy/tmp/cache/assets/test/sprockets/357970feca3ac29060c1e3861e2c0953
|
@@ -100,7 +100,7 @@ files:
|
|
100
100
|
- test/test_helper.rb
|
101
101
|
- test/with_last_test.rb
|
102
102
|
- test/without_last_test.rb
|
103
|
-
homepage: https://github.com/
|
103
|
+
homepage: https://github.com/museways/crumbs
|
104
104
|
licenses:
|
105
105
|
- MIT
|
106
106
|
metadata: {}
|
@@ -110,17 +110,17 @@ require_paths:
|
|
110
110
|
- lib
|
111
111
|
required_ruby_version: !ruby/object:Gem::Requirement
|
112
112
|
requirements:
|
113
|
-
- -
|
113
|
+
- - ">="
|
114
114
|
- !ruby/object:Gem::Version
|
115
115
|
version: '0'
|
116
116
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
117
117
|
requirements:
|
118
|
-
- -
|
118
|
+
- - ">="
|
119
119
|
- !ruby/object:Gem::Version
|
120
120
|
version: '0'
|
121
121
|
requirements: []
|
122
122
|
rubyforge_project:
|
123
|
-
rubygems_version: 2.
|
123
|
+
rubygems_version: 2.2.2
|
124
124
|
signing_key:
|
125
125
|
specification_version: 4
|
126
126
|
summary: Crumbs for Rails.
|
data/lib/crumbs/history.rb
DELETED
@@ -1,34 +0,0 @@
|
|
1
|
-
module Crumbs
|
2
|
-
class History
|
3
|
-
class << self
|
4
|
-
|
5
|
-
def all
|
6
|
-
@all ||= {}
|
7
|
-
end
|
8
|
-
|
9
|
-
def add(controller, action, name)
|
10
|
-
controller = controller.to_sym
|
11
|
-
action = action.to_sym
|
12
|
-
unless all.has_key? controller
|
13
|
-
all[controller] = { action => name }
|
14
|
-
else
|
15
|
-
all[controller][action] = name
|
16
|
-
end
|
17
|
-
end
|
18
|
-
|
19
|
-
def get_name(controller, action, params)
|
20
|
-
controller = controller.to_sym
|
21
|
-
action = action.to_sym
|
22
|
-
return false unless all.has_key? controller and all[controller].has_key? action
|
23
|
-
name = all[controller][action]
|
24
|
-
if name.respond_to? :call
|
25
|
-
value = name.call(params)
|
26
|
-
elsif
|
27
|
-
value = name
|
28
|
-
end
|
29
|
-
value ? value : ''
|
30
|
-
end
|
31
|
-
|
32
|
-
end
|
33
|
-
end
|
34
|
-
end
|