gollum_rails 1.5.10 → 1.5.12
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +13 -5
- data/Gemfile.lock +106 -97
- data/Rakefile +1 -2
- data/gollum_rails.gemspec +14 -8
- data/lib/generators/gollum_rails/language/language_generator.rb +1 -1
- data/lib/gollum_rails.rb +6 -6
- data/lib/gollum_rails/callbacks.rb +10 -12
- data/lib/gollum_rails/core.rb +22 -37
- data/lib/gollum_rails/error.rb +1 -2
- data/lib/gollum_rails/finders.rb +8 -10
- data/lib/gollum_rails/meta.rb +6 -7
- data/lib/gollum_rails/orm.rb +1 -4
- data/lib/gollum_rails/page.rb +6 -11
- data/lib/gollum_rails/persistance.rb +19 -30
- data/lib/gollum_rails/setup.rb +6 -6
- data/lib/gollum_rails/store.rb +11 -11
- data/lib/gollum_rails/validation.rb +2 -2
- data/spec/factories.rb +35 -0
- data/spec/gollum_rails/page_core_spec.rb +35 -0
- data/spec/gollum_rails/page_spec.rb +72 -182
- data/spec/spec_helper.rb +8 -4
- data/spec/support/default_commit.rb +3 -0
- data/spec/support/gollum_page_spec.rb +3 -0
- data/spec/support/special_commit.rb +2 -0
- metadata +75 -42
checksums.yaml
CHANGED
@@ -1,7 +1,15 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
|
2
|
+
!binary "U0hBMQ==":
|
3
|
+
metadata.gz: !binary |-
|
4
|
+
NmY0ZTZlZDNhZDQxZjBiM2YzNzM1NGM5ZTg3NWEzYWY4OTY4MzExNA==
|
5
|
+
data.tar.gz: !binary |-
|
6
|
+
NmNhY2FjODc1YTQ4MThmMDRlNDZhZjliY2Y2NTAzODgyMjY2MTM3Yg==
|
5
7
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
|
8
|
+
metadata.gz: !binary |-
|
9
|
+
NjM5NzEyODg1MWEzZWFlNjg4ZDU0MTdlZDRhODQ0NzlhNDg1ZjUxOWQ0ZDIw
|
10
|
+
NTIzMjU1YjYxZWVlMDI5N2VhMTQ5YzIzMGMxN2VhZGYwYTU3ZDAyODg3N2Vm
|
11
|
+
OTg1NTU3MWMxMjdkZWFjMWI5MzkwZDdhZGQ4Nzg4ODUxNjdjODE=
|
12
|
+
data.tar.gz: !binary |-
|
13
|
+
OWY3NDkyNjdmMmUzZTdmMDAxYjVmMzVlMGFhYjhhOTBjZjAwY2Y1NjBlYWIx
|
14
|
+
YmY3NWFhNWZhZTdiZmFiMmY2YTU1YjkwNDllZTZmM2MxZGQ4NTZjOTVlMzgy
|
15
|
+
MmNjMjA5MjJkYjE2Mzc0ZDAzMzEyMzU0ZTYwNzM4Nzg2YmZjNzE=
|
data/Gemfile.lock
CHANGED
@@ -1,47 +1,45 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
gollum_rails (1.5.
|
4
|
+
gollum_rails (1.5.12)
|
5
5
|
activemodel (>= 3.2.11)
|
6
6
|
activesupport (>= 3.2.11)
|
7
|
-
gollum-lib (~>
|
7
|
+
gollum-lib (~> 3.0.0)
|
8
8
|
|
9
9
|
GEM
|
10
10
|
remote: https://rubygems.org/
|
11
11
|
specs:
|
12
|
-
actionmailer (4.
|
13
|
-
actionpack (= 4.
|
12
|
+
actionmailer (4.1.4)
|
13
|
+
actionpack (= 4.1.4)
|
14
|
+
actionview (= 4.1.4)
|
14
15
|
mail (~> 2.5.4)
|
15
|
-
actionpack (4.
|
16
|
-
|
17
|
-
|
18
|
-
erubis (~> 2.7.0)
|
16
|
+
actionpack (4.1.4)
|
17
|
+
actionview (= 4.1.4)
|
18
|
+
activesupport (= 4.1.4)
|
19
19
|
rack (~> 1.5.2)
|
20
20
|
rack-test (~> 0.6.2)
|
21
|
-
|
22
|
-
activesupport (= 4.
|
23
|
-
builder (~> 3.1
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
21
|
+
actionview (4.1.4)
|
22
|
+
activesupport (= 4.1.4)
|
23
|
+
builder (~> 3.1)
|
24
|
+
erubis (~> 2.7.0)
|
25
|
+
activemodel (4.1.4)
|
26
|
+
activesupport (= 4.1.4)
|
27
|
+
builder (~> 3.1)
|
28
|
+
activerecord (4.1.4)
|
29
|
+
activemodel (= 4.1.4)
|
30
|
+
activesupport (= 4.1.4)
|
31
|
+
arel (~> 5.0.0)
|
32
|
+
activesupport (4.1.4)
|
33
|
+
i18n (~> 0.6, >= 0.6.9)
|
34
|
+
json (~> 1.7, >= 1.7.7)
|
35
|
+
minitest (~> 5.1)
|
34
36
|
thread_safe (~> 0.1)
|
35
|
-
tzinfo (~>
|
36
|
-
arel (
|
37
|
-
|
38
|
-
builder (3.1.4)
|
37
|
+
tzinfo (~> 1.1)
|
38
|
+
arel (5.0.1.20140414130214)
|
39
|
+
builder (3.2.2)
|
39
40
|
celluloid (0.15.2)
|
40
41
|
timers (~> 1.1.0)
|
41
|
-
|
42
|
-
celluloid (>= 0.15.0)
|
43
|
-
nio4r (>= 0.5.0)
|
44
|
-
charlock_holmes (0.6.9.4)
|
42
|
+
charlock_holmes (0.7.3)
|
45
43
|
coderay (1.1.0)
|
46
44
|
coveralls (0.7.0)
|
47
45
|
multi_json (~> 1.3)
|
@@ -50,129 +48,140 @@ GEM
|
|
50
48
|
term-ansicolor
|
51
49
|
thor
|
52
50
|
diff-lcs (1.2.5)
|
53
|
-
docile (1.1.
|
51
|
+
docile (1.1.5)
|
54
52
|
erubis (2.7.0)
|
53
|
+
factory_girl (4.4.0)
|
54
|
+
activesupport (>= 3.0.0)
|
55
55
|
ffi (1.9.3)
|
56
|
-
formatador (0.2.
|
57
|
-
github-markup (
|
58
|
-
|
59
|
-
|
56
|
+
formatador (0.2.5)
|
57
|
+
github-markup (1.1.2)
|
58
|
+
posix-spawn (~> 0.3.8)
|
59
|
+
gitlab-grit (2.6.9)
|
60
|
+
charlock_holmes (~> 0.6)
|
60
61
|
diff-lcs (~> 1.1)
|
61
62
|
mime-types (~> 1.15)
|
62
|
-
posix-spawn (~> 0.3
|
63
|
-
gollum-lib (
|
64
|
-
github-markup (
|
65
|
-
gitlab-grit (
|
66
|
-
nokogiri (~> 1.6.
|
67
|
-
rouge (~> 1.3.
|
68
|
-
sanitize (~> 2.0
|
69
|
-
stringex (~> 2.1
|
70
|
-
guard (2.
|
63
|
+
posix-spawn (~> 0.3)
|
64
|
+
gollum-lib (3.0.0)
|
65
|
+
github-markup (~> 1.1.0)
|
66
|
+
gitlab-grit (~> 2.6.5)
|
67
|
+
nokogiri (~> 1.6.1)
|
68
|
+
rouge (~> 1.3.3)
|
69
|
+
sanitize (~> 2.1.0)
|
70
|
+
stringex (~> 2.5.1)
|
71
|
+
guard (2.6.1)
|
71
72
|
formatador (>= 0.2.4)
|
72
|
-
listen (~> 2.
|
73
|
+
listen (~> 2.7)
|
73
74
|
lumberjack (~> 1.0)
|
74
75
|
pry (>= 0.9.12)
|
75
76
|
thor (>= 0.18.1)
|
76
|
-
guard-rspec (
|
77
|
-
guard (
|
78
|
-
rspec (
|
77
|
+
guard-rspec (4.2.10)
|
78
|
+
guard (~> 2.1)
|
79
|
+
rspec (>= 2.14, < 4.0)
|
80
|
+
hashr (0.0.22)
|
79
81
|
hike (1.2.3)
|
80
82
|
i18n (0.6.9)
|
81
|
-
|
83
|
+
json (1.8.1)
|
84
|
+
listen (2.7.9)
|
82
85
|
celluloid (>= 0.15.2)
|
83
|
-
celluloid-io (>= 0.15.0)
|
84
86
|
rb-fsevent (>= 0.9.3)
|
85
87
|
rb-inotify (>= 0.9)
|
86
|
-
lumberjack (1.0.
|
88
|
+
lumberjack (1.0.9)
|
87
89
|
mail (2.5.4)
|
88
90
|
mime-types (~> 1.16)
|
89
91
|
treetop (~> 1.4.8)
|
90
92
|
method_source (0.8.2)
|
91
93
|
mime-types (1.25.1)
|
92
|
-
mini_portile (0.
|
93
|
-
minitest (
|
94
|
-
multi_json (1.
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
polyglot (0.3.4)
|
94
|
+
mini_portile (0.6.0)
|
95
|
+
minitest (5.3.5)
|
96
|
+
multi_json (1.10.1)
|
97
|
+
nokogiri (1.6.2.1)
|
98
|
+
mini_portile (= 0.6.0)
|
99
|
+
polyglot (0.3.5)
|
99
100
|
posix-spawn (0.3.8)
|
100
|
-
pry (0.
|
101
|
-
coderay (~> 1.0)
|
102
|
-
method_source (~> 0.8)
|
101
|
+
pry (0.10.0)
|
102
|
+
coderay (~> 1.1.0)
|
103
|
+
method_source (~> 0.8.1)
|
103
104
|
slop (~> 3.4)
|
104
105
|
rack (1.5.2)
|
105
106
|
rack-test (0.6.2)
|
106
107
|
rack (>= 1.0)
|
107
|
-
rails (4.
|
108
|
-
actionmailer (= 4.
|
109
|
-
actionpack (= 4.
|
110
|
-
|
111
|
-
|
108
|
+
rails (4.1.4)
|
109
|
+
actionmailer (= 4.1.4)
|
110
|
+
actionpack (= 4.1.4)
|
111
|
+
actionview (= 4.1.4)
|
112
|
+
activemodel (= 4.1.4)
|
113
|
+
activerecord (= 4.1.4)
|
114
|
+
activesupport (= 4.1.4)
|
112
115
|
bundler (>= 1.3.0, < 2.0)
|
113
|
-
railties (= 4.
|
114
|
-
sprockets-rails (~> 2.0
|
115
|
-
railties (4.
|
116
|
-
actionpack (= 4.
|
117
|
-
activesupport (= 4.
|
116
|
+
railties (= 4.1.4)
|
117
|
+
sprockets-rails (~> 2.0)
|
118
|
+
railties (4.1.4)
|
119
|
+
actionpack (= 4.1.4)
|
120
|
+
activesupport (= 4.1.4)
|
118
121
|
rake (>= 0.8.7)
|
119
122
|
thor (>= 0.18.1, < 2.0)
|
120
|
-
rake (10.
|
123
|
+
rake (10.3.2)
|
121
124
|
rb-fsevent (0.9.4)
|
122
|
-
rb-inotify (0.9.
|
125
|
+
rb-inotify (0.9.5)
|
123
126
|
ffi (>= 0.5.0)
|
127
|
+
redcarpet (3.1.2)
|
124
128
|
rest-client (1.6.7)
|
125
129
|
mime-types (>= 1.16)
|
126
|
-
rouge (1.3.
|
127
|
-
|
128
|
-
|
129
|
-
rspec-
|
130
|
-
rspec-
|
131
|
-
|
132
|
-
|
133
|
-
rspec-expectations (
|
134
|
-
diff-lcs (>= 1.
|
135
|
-
|
136
|
-
|
130
|
+
rouge (1.3.4)
|
131
|
+
rspec (3.0.0)
|
132
|
+
rspec-core (~> 3.0.0)
|
133
|
+
rspec-expectations (~> 3.0.0)
|
134
|
+
rspec-mocks (~> 3.0.0)
|
135
|
+
rspec-core (3.0.2)
|
136
|
+
rspec-support (~> 3.0.0)
|
137
|
+
rspec-expectations (3.0.2)
|
138
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
139
|
+
rspec-support (~> 3.0.0)
|
140
|
+
rspec-mocks (3.0.2)
|
141
|
+
rspec-support (~> 3.0.0)
|
142
|
+
rspec-support (3.0.2)
|
143
|
+
sanitize (2.1.0)
|
137
144
|
nokogiri (>= 1.4.4)
|
138
145
|
simplecov (0.8.2)
|
139
146
|
docile (~> 1.1.0)
|
140
147
|
multi_json
|
141
148
|
simplecov-html (~> 0.8.0)
|
142
149
|
simplecov-html (0.8.0)
|
143
|
-
slop (3.
|
144
|
-
sprockets (2.
|
150
|
+
slop (3.5.0)
|
151
|
+
sprockets (2.12.1)
|
145
152
|
hike (~> 1.2)
|
146
153
|
multi_json (~> 1.0)
|
147
154
|
rack (~> 1.0)
|
148
155
|
tilt (~> 1.1, != 1.3.0)
|
149
|
-
sprockets-rails (2.
|
156
|
+
sprockets-rails (2.1.3)
|
150
157
|
actionpack (>= 3.0)
|
151
158
|
activesupport (>= 3.0)
|
152
159
|
sprockets (~> 2.8)
|
153
|
-
stringex (2.
|
160
|
+
stringex (2.5.2)
|
154
161
|
term-ansicolor (1.3.0)
|
155
162
|
tins (~> 1.0)
|
156
|
-
thor (0.
|
157
|
-
thread_safe (0.
|
158
|
-
atomic
|
163
|
+
thor (0.19.1)
|
164
|
+
thread_safe (0.3.4)
|
159
165
|
tilt (1.4.1)
|
160
166
|
timers (1.1.0)
|
161
|
-
tins (1.
|
167
|
+
tins (1.3.0)
|
162
168
|
treetop (1.4.15)
|
163
169
|
polyglot
|
164
170
|
polyglot (>= 0.3.1)
|
165
|
-
tzinfo (
|
171
|
+
tzinfo (1.2.1)
|
172
|
+
thread_safe (~> 0.1)
|
166
173
|
|
167
174
|
PLATFORMS
|
168
175
|
ruby
|
169
176
|
|
170
177
|
DEPENDENCIES
|
171
178
|
coveralls
|
179
|
+
factory_girl (~> 4.4)
|
172
180
|
gollum_rails!
|
173
|
-
guard
|
174
|
-
guard-rspec
|
181
|
+
guard (~> 2.6.0)
|
182
|
+
guard-rspec (~> 4.2.8)
|
183
|
+
hashr (~> 0.0.22)
|
175
184
|
rails (>= 3.2.11)
|
176
|
-
rb-fsevent
|
177
|
-
|
178
|
-
rspec (~>
|
185
|
+
rb-fsevent (>= 0.9.3)
|
186
|
+
redcarpet (>= 3.1.1)
|
187
|
+
rspec (~> 3.0)
|
data/Rakefile
CHANGED
@@ -111,7 +111,7 @@ end
|
|
111
111
|
#############################################################################
|
112
112
|
|
113
113
|
desc 'Create a release build'
|
114
|
-
task :release
|
114
|
+
task :release do
|
115
115
|
unless `git branch` =~ /^\* master$/
|
116
116
|
puts "You must be on the master branch to release!"
|
117
117
|
exit!
|
@@ -121,7 +121,6 @@ task :release => :build do
|
|
121
121
|
sh "git tag v#{version}"
|
122
122
|
sh "git push origin master"
|
123
123
|
sh "git push origin v#{version}"
|
124
|
-
sh "gem push pkg/#{name}-#{version}.gem"
|
125
124
|
end
|
126
125
|
|
127
126
|
desc 'Build gem'
|
data/gollum_rails.gemspec
CHANGED
@@ -4,22 +4,23 @@ Gem::Specification.new do |s|
|
|
4
4
|
s.name = 'gollum_rails'
|
5
5
|
s.rubyforge_project = s.name
|
6
6
|
|
7
|
-
s.version = '1.5.
|
7
|
+
s.version = '1.5.12'
|
8
8
|
|
9
9
|
s.summary = 'Combines Gollum and Rails'
|
10
10
|
s.description= 'include Gollum into Rails with ease'
|
11
11
|
|
12
12
|
s.add_dependency 'activemodel', '>= 3.2.11'
|
13
13
|
s.add_dependency 'activesupport', '>= 3.2.11'
|
14
|
-
|
15
|
-
s.add_dependency 'gollum-lib', '~> 2.0.0'
|
14
|
+
s.add_dependency 'gollum-lib', '~> 3.0.0'
|
16
15
|
|
17
|
-
s.add_development_dependency 'rspec', '~>
|
18
|
-
s.add_development_dependency 'rr', '~> 1.1.1'
|
16
|
+
s.add_development_dependency 'rspec', '~> 3.0'
|
19
17
|
s.add_development_dependency 'rails', '>= 3.2.11'
|
20
|
-
s.add_development_dependency 'guard'
|
21
|
-
s.add_development_dependency 'guard-rspec'
|
22
|
-
s.add_development_dependency 'rb-fsevent'
|
18
|
+
s.add_development_dependency 'guard', '~> 2.6.0'
|
19
|
+
s.add_development_dependency 'guard-rspec', '~> 4.2.8'
|
20
|
+
s.add_development_dependency 'rb-fsevent', '>= 0.9.3'
|
21
|
+
s.add_development_dependency 'redcarpet', '>= 3.1.1'
|
22
|
+
s.add_development_dependency 'factory_girl', '~> 4.4'
|
23
|
+
s.add_development_dependency 'hashr','~> 0.0.22'
|
23
24
|
s.author = 'Florian Kasper'
|
24
25
|
s.email = 'mosny@zyg.li'
|
25
26
|
s.homepage = 'https://github.com/nirnanaaa/gollum_rails'
|
@@ -57,11 +58,16 @@ Gem::Specification.new do |s|
|
|
57
58
|
lib/gollum_rails/setup/options.rb
|
58
59
|
lib/gollum_rails/store.rb
|
59
60
|
lib/gollum_rails/validation.rb
|
61
|
+
spec/factories.rb
|
62
|
+
spec/gollum_rails/page_core_spec.rb
|
60
63
|
spec/gollum_rails/page_spec.rb
|
61
64
|
spec/gollum_rails/respository_spec.rb
|
62
65
|
spec/gollum_rails/setup_spec.rb
|
63
66
|
spec/gollum_rails/wiki_spec.rb
|
64
67
|
spec/spec_helper.rb
|
68
|
+
spec/support/default_commit.rb
|
69
|
+
spec/support/gollum_page_spec.rb
|
70
|
+
spec/support/special_commit.rb
|
65
71
|
]
|
66
72
|
# = MANIFEST =
|
67
73
|
|
data/lib/gollum_rails.rb
CHANGED
@@ -1,17 +1,17 @@
|
|
1
1
|
# ~*~ encoding: utf-8 ~*~
|
2
2
|
#--
|
3
3
|
# Copyright (C) 2013 Florian Kasper
|
4
|
-
#
|
4
|
+
#
|
5
5
|
# This program is free software: you can redistribute it and/or modify
|
6
6
|
# it under the terms of the GNU Affero General Public License as published by
|
7
7
|
# the Free Software Foundation, either version 3 of the License, or
|
8
8
|
# (at your option) any later version.
|
9
|
-
#
|
9
|
+
#
|
10
10
|
# This program is distributed in the hope that it will be useful,
|
11
11
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
12
12
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
13
13
|
# GNU Affero General Public License for more details.
|
14
|
-
#
|
14
|
+
#
|
15
15
|
# You should have received a copy of the GNU Affero General Public License
|
16
16
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
17
17
|
#++
|
@@ -27,7 +27,7 @@ require 'active_support'
|
|
27
27
|
#
|
28
28
|
module GollumRails
|
29
29
|
extend ActiveSupport::Autoload
|
30
|
-
|
30
|
+
|
31
31
|
autoload :Persistance
|
32
32
|
autoload :Callbacks
|
33
33
|
autoload :Error
|
@@ -40,8 +40,8 @@ module GollumRails
|
|
40
40
|
autoload :Orm
|
41
41
|
autoload :Meta
|
42
42
|
|
43
|
-
# GollumRails version
|
44
|
-
VERSION = '1.5.
|
43
|
+
# GollumRails version
|
44
|
+
VERSION = '1.5.12'
|
45
45
|
|
46
46
|
end
|
47
47
|
|
@@ -1,34 +1,32 @@
|
|
1
1
|
module GollumRails
|
2
2
|
module Callbacks
|
3
3
|
extend ActiveSupport::Concern
|
4
|
-
|
4
|
+
|
5
5
|
CALLBACKS = [
|
6
6
|
:after_initialize,
|
7
7
|
:before_save, :around_save, :after_save, :before_create, :around_create,
|
8
8
|
:after_create, :before_update, :around_update, :after_update,
|
9
9
|
:before_destroy, :around_destroy, :after_destroy, :after_commit
|
10
10
|
]
|
11
|
+
|
11
12
|
module ClassMethods
|
12
13
|
include ActiveModel::Callbacks
|
13
14
|
end
|
14
|
-
|
15
|
+
|
15
16
|
included do
|
16
17
|
include ActiveModel::Validations::Callbacks
|
17
|
-
|
18
18
|
define_model_callbacks :initialize, :only => :after
|
19
19
|
define_model_callbacks :save, :create, :update, :destroy
|
20
20
|
end
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
def destroy(*)
|
21
|
+
|
22
|
+
def destroy(*) #:nodoc:
|
25
23
|
run_callbacks(:destroy) { super }
|
26
24
|
end
|
27
|
-
|
28
|
-
def save
|
25
|
+
|
26
|
+
def save #:nodoc:
|
29
27
|
run_callbacks(:save) { super }
|
30
|
-
end
|
31
|
-
|
28
|
+
end
|
29
|
+
|
32
30
|
private
|
33
31
|
|
34
32
|
def create_or_update #:nodoc:
|
@@ -42,6 +40,6 @@ module GollumRails
|
|
42
40
|
def update_record(*) #:nodoc:
|
43
41
|
run_callbacks(:update) { super }
|
44
42
|
end
|
45
|
-
|
43
|
+
|
46
44
|
end
|
47
45
|
end
|