paraphrase 0.7.0 → 0.8.0
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 +4 -4
- data/.travis.yml +12 -0
- data/Appraisals +4 -0
- data/CHANGELOG.md +53 -0
- data/README.md +132 -81
- data/gemfiles/3.0.gemfile +1 -0
- data/gemfiles/3.0.gemfile.lock +28 -2
- data/gemfiles/3.1.gemfile +1 -0
- data/gemfiles/3.1.gemfile.lock +28 -2
- data/gemfiles/3.2.gemfile +1 -0
- data/gemfiles/3.2.gemfile.lock +28 -2
- data/gemfiles/4.0.gemfile +1 -0
- data/gemfiles/4.0.gemfile.lock +14 -2
- data/lib/paraphrase/active_model.rb +30 -0
- data/lib/paraphrase/query.rb +66 -49
- data/lib/paraphrase/rails.rb +1 -2
- data/lib/paraphrase/scope.rb +56 -0
- data/lib/paraphrase/syntax.rb +15 -60
- data/lib/paraphrase/version.rb +1 -1
- data/lib/paraphrase.rb +1 -0
- data/paraphrase.gemspec +17 -4
- data/spec/paraphrase/query_spec.rb +113 -45
- data/spec/paraphrase/scope_spec.rb +51 -0
- data/spec/paraphrase/syntax_spec.rb +26 -7
- data/spec/spec_helper.rb +60 -1
- metadata +97 -57
- data/CHANGELOG +0 -39
- data/lib/paraphrase/scope_mapping.rb +0 -78
- data/spec/paraphrase/scope_mapping_spec.rb +0 -46
- data/spec/support/database.rb +0 -38
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 495b5b3b50b22aed23b4b684084c4213dfa6648d
|
4
|
+
data.tar.gz: 25742c98d2fea7b1b65f64c0694a5b6fa2888005
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 900028635ad15f53e571fc5af6f589886b4b814930a91f084ce8c387798a379b04d29c8876d373685e9434b33e207f948d87e3ced0e2f0f8f8ba7258f8fc7fce
|
7
|
+
data.tar.gz: 11deef4d8d8a299018766bd1f7d9ced8dea177594e9a549e0479b0035e1cbe1df9da1f8e82aaa554ceba33492d76371f5d0fe1c685deb6213f0949f4cd3c4472
|
data/.travis.yml
ADDED
data/Appraisals
CHANGED
@@ -1,19 +1,23 @@
|
|
1
1
|
appraise '3.0' do
|
2
2
|
gem 'activerecord', '~> 3.0'
|
3
3
|
gem 'activesupport', '~> 3.0'
|
4
|
+
gem 'actionpack', '~> 3.0'
|
4
5
|
end
|
5
6
|
|
6
7
|
appraise '3.1' do
|
7
8
|
gem 'activerecord', '~> 3.1'
|
8
9
|
gem 'activesupport', '~> 3.1'
|
10
|
+
gem 'actionpack', '~> 3.1'
|
9
11
|
end
|
10
12
|
|
11
13
|
appraise '3.2' do
|
12
14
|
gem 'activerecord', '~> 3.2'
|
13
15
|
gem 'activesupport', '~> 3.2'
|
16
|
+
gem 'actionpack', '~> 3.2'
|
14
17
|
end
|
15
18
|
|
16
19
|
appraise '4.0' do
|
17
20
|
gem 'activerecord', '~> 4.0'
|
18
21
|
gem 'activesupport', '~> 4.0'
|
22
|
+
gem 'actionpack', '~> 4.0'
|
19
23
|
end
|
data/CHANGELOG.md
ADDED
@@ -0,0 +1,53 @@
|
|
1
|
+
## 0.8.0 / 2-5-2014
|
2
|
+
|
3
|
+
* Remove `ActiveSupport::Notifications`
|
4
|
+
* Remove delegation to `Query#results`
|
5
|
+
* Rename `Query#results` to `Query#result`
|
6
|
+
* Add support for use with form builders
|
7
|
+
* Remove `:require` option in `map`
|
8
|
+
* Change method signature of `map`. Now accepts a list of keys followed by a
|
9
|
+
hash of options. the `:to` option points to the name of the scope that should
|
10
|
+
be called with the values of the supplied keys.
|
11
|
+
* Determine the name of the source ActiveRecord::Base sublcass from the name of
|
12
|
+
the query class
|
13
|
+
* Remove `register_mapping` method added to `ActiveRecord::Base`.
|
14
|
+
|
15
|
+
## 0.7.0 / 1-25-2014
|
16
|
+
|
17
|
+
* Add Rails 4 support
|
18
|
+
|
19
|
+
## 0.5.0 / 8-7-2012
|
20
|
+
|
21
|
+
* Cleanup `ScopeMapping` class
|
22
|
+
* Add ability to query from an existing `ActiveRecord::Relation` instance
|
23
|
+
(typically an association).
|
24
|
+
* Update syntax for generating mappings.
|
25
|
+
|
26
|
+
## 0.4.0 / 7-6-2012
|
27
|
+
|
28
|
+
* Setup `Query#params` to be `HashWithIndifferentAccess`.
|
29
|
+
* Gut out `Paraphrase` module methods. These were for use cases I had planned
|
30
|
+
for but have yet to encounter.
|
31
|
+
* Model's query class is now stored on the model itself.
|
32
|
+
|
33
|
+
## 0.3.2 / 7-5-2012
|
34
|
+
|
35
|
+
* Cache `Query#results`
|
36
|
+
* Setup `Query#method_missing` to proxy to `Query#results`
|
37
|
+
* Setup `Query#respond_to?` to check `Query#results`
|
38
|
+
|
39
|
+
## 0.3.1 / 7-5-2012
|
40
|
+
|
41
|
+
* Fix for rails 3.0
|
42
|
+
|
43
|
+
## 0.3.0 / 7-5-2012
|
44
|
+
|
45
|
+
* Allow `nil` values to be passed to scoped using `:allow_nil` option.
|
46
|
+
* Require/whitelist individual keys of a compound key.
|
47
|
+
* Update `Paraphrase::Syntax.register_mapping` to update an existing mapping to
|
48
|
+
avoid errors when a model class is reloaded during development.
|
49
|
+
|
50
|
+
## 0.2.0 / 6-22-2012
|
51
|
+
|
52
|
+
* Initial release
|
53
|
+
|
data/README.md
CHANGED
@@ -2,12 +2,8 @@
|
|
2
2
|
|
3
3
|
[](https://codeclimate.com/github/ecbypi/paraphrase)
|
4
4
|
|
5
|
-
Paraphrase provides a way to map
|
6
|
-
scopes
|
7
|
-
your model classes and `ActiveRecord::Relation` instances that, after setting
|
8
|
-
up your scope => key mappings, will apply scopes if the parameters mapped to a
|
9
|
-
scope are present. You can also require and whitelist certain parameters to
|
10
|
-
provide more flexibility on complex scopes.
|
5
|
+
Paraphrase provides a way to map query params to model scopes and
|
6
|
+
only apply scopes when the mapped query params are present.
|
11
7
|
|
12
8
|
## Installation
|
13
9
|
|
@@ -25,41 +21,51 @@ $ gem install paraphrase
|
|
25
21
|
|
26
22
|
## Usage
|
27
23
|
|
28
|
-
|
29
|
-
|
24
|
+
Subclass `Paraphrase::Query` and use `map` to define what query params should
|
25
|
+
be applied to which scopes.
|
30
26
|
|
31
27
|
```ruby
|
32
28
|
# app/queries/post_query.rb
|
33
29
|
class PostQuery < Paraphrase::Query
|
34
|
-
map :
|
35
|
-
|
36
|
-
|
37
|
-
# or
|
38
|
-
|
39
|
-
# app/models/post.rb
|
40
|
-
class Post < ActiveRecord::Base
|
41
|
-
belongs_to :user
|
30
|
+
map :author, to: :by_user
|
31
|
+
map :start_date, :end_date, to: :published_within
|
42
32
|
|
43
|
-
|
44
|
-
|
33
|
+
def start_date
|
34
|
+
Time.zone.parse(params[:start_date])
|
45
35
|
end
|
36
|
+
end
|
37
|
+
```
|
46
38
|
|
47
|
-
|
48
|
-
|
49
|
-
|
39
|
+
By default, the `ActiveRecord` class is introspected from the demodulized class
|
40
|
+
name of the `Paraphrase::Query` sublcass. If the name of the query class is
|
41
|
+
not `<model>Query`, the source can be manually specified by passing a string or
|
42
|
+
symbol to the `source` method.
|
43
|
+
|
44
|
+
```ruby
|
45
|
+
# app/queries/admin_post_query.rb
|
46
|
+
class AdminPostQuery < Paraphrase::Query
|
47
|
+
# This needs the source specific since it will look for an `AdminPost` model.
|
48
|
+
source :Post
|
50
49
|
end
|
51
50
|
```
|
52
51
|
|
53
|
-
In the controller, call `.paraphrase` on your model, passing
|
54
|
-
|
55
|
-
|
56
|
-
|
52
|
+
In the controller, call `.paraphrase` on your model, passing a hash of query
|
53
|
+
params. This will filter out the registered query params, calling the scopes
|
54
|
+
whose inputs are supplied. If a query param for a scope is missing or empty,
|
55
|
+
the scope is skipped.
|
56
|
+
|
57
|
+
`Paraphrase::Query` will intelligently determine if the value of the query
|
58
|
+
param is empty. If the value is an array containing empty strings, the empty
|
59
|
+
strings will be removed before being passed to the scope. If the array is empty
|
60
|
+
after removing empty strings, the scope will not be called since an empty array
|
61
|
+
is considered a blank value.
|
57
62
|
|
58
63
|
```ruby
|
59
64
|
class PostsController < ApplicationController
|
60
65
|
respond_to :html, :json
|
61
66
|
|
62
67
|
def index
|
68
|
+
# Will filter out keys such as `:action` and `:controller`
|
63
69
|
@posts = Post.paraphrase(params)
|
64
70
|
respond_with(@posts)
|
65
71
|
end
|
@@ -68,7 +74,7 @@ end
|
|
68
74
|
|
69
75
|
You can chain queries on an `ActiveRecord::Relation`. This avoids adding scopes
|
70
76
|
that replicate the functionality of an association like
|
71
|
-
`Post.for_user(user_id)` or
|
77
|
+
`Post.for_user(user_id)` or allow you to build a default scope.
|
72
78
|
|
73
79
|
```ruby
|
74
80
|
class PostsController < ApplicationController
|
@@ -79,10 +85,13 @@ class PostsController < ApplicationController
|
|
79
85
|
@user = User.find(params[:user_id])
|
80
86
|
|
81
87
|
# This will scope the query to posts where `posts`.`user_id` = `users`.`id`
|
82
|
-
@posts = @users.posts.paraphrase(params)
|
88
|
+
@posts = @users.posts.paraphrase(params[:q])
|
83
89
|
|
84
90
|
# Or you can build at a different point in a scope chain
|
85
|
-
# @posts = @user.posts.published.paraphrase(params)
|
91
|
+
# @posts = @user.posts.published.paraphrase(params[:q])
|
92
|
+
#
|
93
|
+
# Order is independent too
|
94
|
+
# @posts = @user.posts.paraphrase(params[:q]).published
|
86
95
|
|
87
96
|
respond_with(@posts)
|
88
97
|
end
|
@@ -96,103 +105,145 @@ Scopes are mapped to param keys using the `map` class method provided by
|
|
96
105
|
|
97
106
|
```ruby
|
98
107
|
class PostQuery < Paraphrase::Query
|
99
|
-
map :
|
100
|
-
map :
|
108
|
+
map :first_name, :last_name, to: :by_user
|
109
|
+
map :pub_date, to: :pub_date
|
101
110
|
end
|
102
111
|
|
103
112
|
class Post < ActiveRecord::Base
|
104
113
|
def self.by_user(first_name, last_name)
|
105
|
-
joins(:user).where(:
|
114
|
+
joins(:user).where(user: { first_name: first_name, last_name: last_name })
|
106
115
|
end
|
107
116
|
|
108
117
|
def self.published_on(pub_date)
|
109
|
-
where(:
|
118
|
+
where(published_on: pub_date)
|
110
119
|
end
|
111
120
|
end
|
112
121
|
```
|
113
122
|
|
114
|
-
If
|
115
|
-
|
116
|
-
|
117
|
-
array, you can specify a subset of the key to be required. In this case, the rest of the
|
118
|
-
attributes will be whitelisted.
|
123
|
+
If multiple query params are mapped to a scope, but only a subset are required,
|
124
|
+
use the `:whitelist` option to allow them to be missing. The `:whitelist`
|
125
|
+
option can be set to `true`, an individual key or an array of keys.
|
119
126
|
|
120
127
|
```ruby
|
121
|
-
class
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
# requires only :last_name to be passed in, :first_name can be nil
|
127
|
-
map :by_author, :to => [:first_name, :last_name], :require => :last_name
|
128
|
-
end
|
128
|
+
class PostQuery < Paraphrase::Query
|
129
|
+
# requires only :last_name to be passed in, :first_name can be nil
|
130
|
+
map :first_name, :last_name, to: :by_author, whitelist: :last_name
|
131
|
+
end
|
129
132
|
|
133
|
+
class Post < ActiveRecord::Base
|
130
134
|
def self.by_author(first_name, last_name)
|
131
|
-
query = where(:
|
135
|
+
query = where(user: { first_name: first_name })
|
132
136
|
|
133
|
-
if
|
134
|
-
query.where(:
|
137
|
+
if last_name
|
138
|
+
query = query.where(user: { last_name: last_name })
|
135
139
|
end
|
136
140
|
|
137
141
|
query
|
138
142
|
end
|
139
143
|
end
|
140
144
|
|
141
|
-
Post.paraphrase(
|
142
|
-
|
143
|
-
|
144
|
-
Alternatively, a scope or a subset of its keys can be whitelisted allowing nil
|
145
|
-
values to be passed to the scope. This is intended for scopes that alter their
|
146
|
-
behavior conditionally on a parameter being present. You should whitelist
|
147
|
-
inputs if you still want other scopes to be applied as requiring them will halt
|
148
|
-
execution of scopes and return an empty result set.
|
145
|
+
Post.paraphrase(first_name: 'John').to_sql
|
146
|
+
# => SELECT "posts".* FROM "posts" WHERE "posts"."first_name" = 'John'
|
149
147
|
|
150
|
-
|
151
|
-
|
152
|
-
register_mapping do
|
153
|
-
# :first_name can be nil, :last_name is still required to apply the scope
|
154
|
-
map :by_author, :to => [:first_name, :last_name], :whitelist => :first_name
|
155
|
-
end
|
156
|
-
end
|
148
|
+
Post.paraphrase(first_name: 'John', last_name: 'Smith').to_sql
|
149
|
+
# => SELECT "posts".* FROM "posts" WHERE "posts"."first_name" = 'John' AND "posts"."last_name" = 'Smith'
|
157
150
|
```
|
158
151
|
|
159
152
|
### Boolean Scopes
|
160
153
|
|
161
|
-
Some
|
162
|
-
|
163
|
-
requirng them to would couple them to `Paraphrase::Query` classes in a
|
164
|
-
complicated way.
|
154
|
+
Some filter records based on a boolean column. It doesn't make sense for these
|
155
|
+
methods to take any arguments.
|
165
156
|
|
166
157
|
Paraphrase will detect if the method specified takes no arguments. If not, it
|
167
158
|
will call the method without any arguments, assuming the inputs are present and
|
168
159
|
valid.
|
169
160
|
|
170
161
|
```ruby
|
171
|
-
class
|
172
|
-
|
173
|
-
|
174
|
-
end
|
162
|
+
class PostQuery < Paraphrase::Query
|
163
|
+
map :published, to: :published
|
164
|
+
end
|
175
165
|
|
176
|
-
|
177
|
-
#
|
166
|
+
class Post < ActiveRecord::Base
|
167
|
+
# If the params supplied include a non-empty value for :published, this
|
168
|
+
# method will be called.
|
178
169
|
def self.published
|
179
170
|
where('published_at IS NOT NULL')
|
180
171
|
end
|
181
172
|
end
|
173
|
+
|
174
|
+
Post.paraphrase(published: '1').to_sql
|
175
|
+
# => SELECT "posts".* FROM "posts" WHERE "posts"."published" = 't'
|
182
176
|
```
|
183
177
|
|
184
|
-
###
|
178
|
+
### Pre-processing Query Params
|
185
179
|
|
186
|
-
|
180
|
+
By default, for each query param specified that maps to a model scope, a method
|
181
|
+
is defined on the query class that fetches the value for that key. This is used
|
182
|
+
internally to determine if model scopes need to be applied. To pre-process a
|
183
|
+
query param, such as an ISO formatted date, override the method in the query
|
184
|
+
class.
|
187
185
|
|
188
186
|
```ruby
|
189
|
-
|
190
|
-
|
187
|
+
class PostQuery < Paraphrase::Query
|
188
|
+
map :start_date, :end_date, to: :published_within
|
189
|
+
|
190
|
+
def start_date
|
191
|
+
@start_date ||= Time.zone.parse(params[:start_date]) rescue nil
|
192
|
+
end
|
193
|
+
|
194
|
+
def end_date
|
195
|
+
@start_date ||= Time.zone.parse(params[:end_date]) rescue nil
|
196
|
+
end
|
197
|
+
end
|
198
|
+
|
199
|
+
class Post < ActiveRecord::Base
|
200
|
+
def self.published_within(start_date, end_date)
|
201
|
+
where(published_at: start_date..end_date)
|
202
|
+
end
|
191
203
|
end
|
204
|
+
|
205
|
+
Post.parahrase(start_date: '201-03-21', end_date: '2013-03-25').to_sql
|
206
|
+
# => SELECT "posts".* FROM "posts"
|
192
207
|
```
|
193
208
|
|
194
|
-
`
|
209
|
+
In the above example, if either `:start_date` or `:end_date` are incorrectly
|
210
|
+
formatted, the `pubished_within` scope will not be applied because the values
|
211
|
+
are will be `nil`.
|
212
|
+
|
213
|
+
### Using with `FormBuilder`
|
214
|
+
|
215
|
+
The `Paraphrase::Query` class implements the `ActiveModel` API required for use with form builders.
|
216
|
+
|
217
|
+
```ruby
|
218
|
+
class PostQuery < Paraphrase::Query
|
219
|
+
map :author, to: :by_user
|
220
|
+
end
|
221
|
+
|
222
|
+
class PostsController < ApplicationController
|
223
|
+
def index
|
224
|
+
@query = PostQuery.new(params[:q])
|
225
|
+
@posts = query.result
|
226
|
+
end
|
227
|
+
end
|
228
|
+
```
|
229
|
+
|
230
|
+
```erb
|
231
|
+
<%= form_for @query, url: posts_url, method: :get do |f| %>
|
232
|
+
<%= f.label :author %>
|
233
|
+
<%= f.select :author, options_from_collection_for_select(User.authors, :id, :name) %>
|
234
|
+
<% end %>
|
235
|
+
|
236
|
+
<% @posts.each do |post| %>
|
237
|
+
...
|
238
|
+
<% end %>
|
239
|
+
```
|
240
|
+
|
241
|
+
## Contributing
|
242
|
+
|
243
|
+
Contributions welcome. Be sure to include tests for any regressions or features.
|
195
244
|
|
196
|
-
|
197
|
-
|
198
|
-
|
245
|
+
1. Fork it ( http://github.com/[my-github-username]/paraphrase/fork )
|
246
|
+
2. Create your feature branch (`git checkout -b my-new-feature`)
|
247
|
+
3. Commit your changes (`git commit -am 'Add some feature with tests'`)
|
248
|
+
4. Push to the branch (`git push origin my-new-feature`)
|
249
|
+
5. Create new Pull Request
|
data/gemfiles/3.0.gemfile
CHANGED
data/gemfiles/3.0.gemfile.lock
CHANGED
@@ -1,13 +1,24 @@
|
|
1
1
|
PATH
|
2
2
|
remote: /Users/edd_d/Work/paraphrase
|
3
3
|
specs:
|
4
|
-
paraphrase (0.
|
4
|
+
paraphrase (0.8.0)
|
5
|
+
activemodel (>= 3.0, < 4.1)
|
5
6
|
activerecord (>= 3.0, < 4.1)
|
6
7
|
activesupport (>= 3.0, < 4.1)
|
7
8
|
|
8
9
|
GEM
|
9
10
|
remote: https://rubygems.org/
|
10
11
|
specs:
|
12
|
+
actionpack (3.2.16)
|
13
|
+
activemodel (= 3.2.16)
|
14
|
+
activesupport (= 3.2.16)
|
15
|
+
builder (~> 3.0.0)
|
16
|
+
erubis (~> 2.7.0)
|
17
|
+
journey (~> 1.0.4)
|
18
|
+
rack (~> 1.4.5)
|
19
|
+
rack-cache (~> 1.2)
|
20
|
+
rack-test (~> 0.6.1)
|
21
|
+
sprockets (~> 2.2.1)
|
11
22
|
activemodel (3.2.16)
|
12
23
|
activesupport (= 3.2.16)
|
13
24
|
builder (~> 3.0.0)
|
@@ -26,13 +37,21 @@ GEM
|
|
26
37
|
builder (3.0.4)
|
27
38
|
coderay (1.1.0)
|
28
39
|
diff-lcs (1.2.5)
|
40
|
+
erubis (2.7.0)
|
41
|
+
hike (1.2.3)
|
29
42
|
i18n (0.6.9)
|
43
|
+
journey (1.0.4)
|
30
44
|
method_source (0.8.2)
|
31
45
|
multi_json (1.8.4)
|
32
46
|
pry (0.9.12.4)
|
33
47
|
coderay (~> 1.0)
|
34
48
|
method_source (~> 0.8)
|
35
49
|
slop (~> 3.4)
|
50
|
+
rack (1.4.5)
|
51
|
+
rack-cache (1.2)
|
52
|
+
rack (>= 0.4)
|
53
|
+
rack-test (0.6.2)
|
54
|
+
rack (>= 1.0)
|
36
55
|
rake (0.9.6)
|
37
56
|
redcarpet (2.1.1)
|
38
57
|
rspec (2.14.1)
|
@@ -44,7 +63,13 @@ GEM
|
|
44
63
|
diff-lcs (>= 1.1.3, < 2.0)
|
45
64
|
rspec-mocks (2.14.4)
|
46
65
|
slop (3.4.7)
|
66
|
+
sprockets (2.2.2)
|
67
|
+
hike (~> 1.2)
|
68
|
+
multi_json (~> 1.0)
|
69
|
+
rack (~> 1.0)
|
70
|
+
tilt (~> 1.1, != 1.3.0)
|
47
71
|
sqlite3 (1.3.8)
|
72
|
+
tilt (1.4.1)
|
48
73
|
tzinfo (0.3.38)
|
49
74
|
yard (0.8.7.3)
|
50
75
|
|
@@ -52,6 +77,7 @@ PLATFORMS
|
|
52
77
|
ruby
|
53
78
|
|
54
79
|
DEPENDENCIES
|
80
|
+
actionpack (~> 3.0)
|
55
81
|
activerecord (~> 3.0)
|
56
82
|
activesupport (~> 3.0)
|
57
83
|
appraisal (~> 0.4)
|
@@ -60,6 +86,6 @@ DEPENDENCIES
|
|
60
86
|
pry (~> 0.9)
|
61
87
|
rake (~> 0.9.2)
|
62
88
|
redcarpet (~> 2.1.1)
|
63
|
-
rspec (~> 2.
|
89
|
+
rspec (~> 2.14)
|
64
90
|
sqlite3 (~> 1.3.6)
|
65
91
|
yard (~> 0.7)
|
data/gemfiles/3.1.gemfile
CHANGED
data/gemfiles/3.1.gemfile.lock
CHANGED
@@ -1,13 +1,24 @@
|
|
1
1
|
PATH
|
2
2
|
remote: /Users/edd_d/Work/paraphrase
|
3
3
|
specs:
|
4
|
-
paraphrase (0.
|
4
|
+
paraphrase (0.8.0)
|
5
|
+
activemodel (>= 3.0, < 4.1)
|
5
6
|
activerecord (>= 3.0, < 4.1)
|
6
7
|
activesupport (>= 3.0, < 4.1)
|
7
8
|
|
8
9
|
GEM
|
9
10
|
remote: https://rubygems.org/
|
10
11
|
specs:
|
12
|
+
actionpack (3.2.16)
|
13
|
+
activemodel (= 3.2.16)
|
14
|
+
activesupport (= 3.2.16)
|
15
|
+
builder (~> 3.0.0)
|
16
|
+
erubis (~> 2.7.0)
|
17
|
+
journey (~> 1.0.4)
|
18
|
+
rack (~> 1.4.5)
|
19
|
+
rack-cache (~> 1.2)
|
20
|
+
rack-test (~> 0.6.1)
|
21
|
+
sprockets (~> 2.2.1)
|
11
22
|
activemodel (3.2.16)
|
12
23
|
activesupport (= 3.2.16)
|
13
24
|
builder (~> 3.0.0)
|
@@ -26,13 +37,21 @@ GEM
|
|
26
37
|
builder (3.0.4)
|
27
38
|
coderay (1.1.0)
|
28
39
|
diff-lcs (1.2.5)
|
40
|
+
erubis (2.7.0)
|
41
|
+
hike (1.2.3)
|
29
42
|
i18n (0.6.9)
|
43
|
+
journey (1.0.4)
|
30
44
|
method_source (0.8.2)
|
31
45
|
multi_json (1.8.4)
|
32
46
|
pry (0.9.12.4)
|
33
47
|
coderay (~> 1.0)
|
34
48
|
method_source (~> 0.8)
|
35
49
|
slop (~> 3.4)
|
50
|
+
rack (1.4.5)
|
51
|
+
rack-cache (1.2)
|
52
|
+
rack (>= 0.4)
|
53
|
+
rack-test (0.6.2)
|
54
|
+
rack (>= 1.0)
|
36
55
|
rake (0.9.6)
|
37
56
|
redcarpet (2.1.1)
|
38
57
|
rspec (2.14.1)
|
@@ -44,7 +63,13 @@ GEM
|
|
44
63
|
diff-lcs (>= 1.1.3, < 2.0)
|
45
64
|
rspec-mocks (2.14.4)
|
46
65
|
slop (3.4.7)
|
66
|
+
sprockets (2.2.2)
|
67
|
+
hike (~> 1.2)
|
68
|
+
multi_json (~> 1.0)
|
69
|
+
rack (~> 1.0)
|
70
|
+
tilt (~> 1.1, != 1.3.0)
|
47
71
|
sqlite3 (1.3.8)
|
72
|
+
tilt (1.4.1)
|
48
73
|
tzinfo (0.3.38)
|
49
74
|
yard (0.8.7.3)
|
50
75
|
|
@@ -52,6 +77,7 @@ PLATFORMS
|
|
52
77
|
ruby
|
53
78
|
|
54
79
|
DEPENDENCIES
|
80
|
+
actionpack (~> 3.1)
|
55
81
|
activerecord (~> 3.1)
|
56
82
|
activesupport (~> 3.1)
|
57
83
|
appraisal (~> 0.4)
|
@@ -60,6 +86,6 @@ DEPENDENCIES
|
|
60
86
|
pry (~> 0.9)
|
61
87
|
rake (~> 0.9.2)
|
62
88
|
redcarpet (~> 2.1.1)
|
63
|
-
rspec (~> 2.
|
89
|
+
rspec (~> 2.14)
|
64
90
|
sqlite3 (~> 1.3.6)
|
65
91
|
yard (~> 0.7)
|
data/gemfiles/3.2.gemfile
CHANGED
data/gemfiles/3.2.gemfile.lock
CHANGED
@@ -1,13 +1,24 @@
|
|
1
1
|
PATH
|
2
2
|
remote: /Users/edd_d/Work/paraphrase
|
3
3
|
specs:
|
4
|
-
paraphrase (0.
|
4
|
+
paraphrase (0.8.0)
|
5
|
+
activemodel (>= 3.0, < 4.1)
|
5
6
|
activerecord (>= 3.0, < 4.1)
|
6
7
|
activesupport (>= 3.0, < 4.1)
|
7
8
|
|
8
9
|
GEM
|
9
10
|
remote: https://rubygems.org/
|
10
11
|
specs:
|
12
|
+
actionpack (3.2.16)
|
13
|
+
activemodel (= 3.2.16)
|
14
|
+
activesupport (= 3.2.16)
|
15
|
+
builder (~> 3.0.0)
|
16
|
+
erubis (~> 2.7.0)
|
17
|
+
journey (~> 1.0.4)
|
18
|
+
rack (~> 1.4.5)
|
19
|
+
rack-cache (~> 1.2)
|
20
|
+
rack-test (~> 0.6.1)
|
21
|
+
sprockets (~> 2.2.1)
|
11
22
|
activemodel (3.2.16)
|
12
23
|
activesupport (= 3.2.16)
|
13
24
|
builder (~> 3.0.0)
|
@@ -26,13 +37,21 @@ GEM
|
|
26
37
|
builder (3.0.4)
|
27
38
|
coderay (1.1.0)
|
28
39
|
diff-lcs (1.2.5)
|
40
|
+
erubis (2.7.0)
|
41
|
+
hike (1.2.3)
|
29
42
|
i18n (0.6.9)
|
43
|
+
journey (1.0.4)
|
30
44
|
method_source (0.8.2)
|
31
45
|
multi_json (1.8.4)
|
32
46
|
pry (0.9.12.4)
|
33
47
|
coderay (~> 1.0)
|
34
48
|
method_source (~> 0.8)
|
35
49
|
slop (~> 3.4)
|
50
|
+
rack (1.4.5)
|
51
|
+
rack-cache (1.2)
|
52
|
+
rack (>= 0.4)
|
53
|
+
rack-test (0.6.2)
|
54
|
+
rack (>= 1.0)
|
36
55
|
rake (0.9.6)
|
37
56
|
redcarpet (2.1.1)
|
38
57
|
rspec (2.14.1)
|
@@ -44,7 +63,13 @@ GEM
|
|
44
63
|
diff-lcs (>= 1.1.3, < 2.0)
|
45
64
|
rspec-mocks (2.14.4)
|
46
65
|
slop (3.4.7)
|
66
|
+
sprockets (2.2.2)
|
67
|
+
hike (~> 1.2)
|
68
|
+
multi_json (~> 1.0)
|
69
|
+
rack (~> 1.0)
|
70
|
+
tilt (~> 1.1, != 1.3.0)
|
47
71
|
sqlite3 (1.3.8)
|
72
|
+
tilt (1.4.1)
|
48
73
|
tzinfo (0.3.38)
|
49
74
|
yard (0.8.7.3)
|
50
75
|
|
@@ -52,6 +77,7 @@ PLATFORMS
|
|
52
77
|
ruby
|
53
78
|
|
54
79
|
DEPENDENCIES
|
80
|
+
actionpack (~> 3.2)
|
55
81
|
activerecord (~> 3.2)
|
56
82
|
activesupport (~> 3.2)
|
57
83
|
appraisal (~> 0.4)
|
@@ -60,6 +86,6 @@ DEPENDENCIES
|
|
60
86
|
pry (~> 0.9)
|
61
87
|
rake (~> 0.9.2)
|
62
88
|
redcarpet (~> 2.1.1)
|
63
|
-
rspec (~> 2.
|
89
|
+
rspec (~> 2.14)
|
64
90
|
sqlite3 (~> 1.3.6)
|
65
91
|
yard (~> 0.7)
|