orm_adapter-sequel 0.0.3 → 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
data/.gitignore CHANGED
@@ -1,16 +1,9 @@
1
- # system crap
2
1
  .DS_Store
3
-
4
- # local ruby/gems dev stuff
5
2
  .rvmrc
6
3
  .bundle
7
4
  Gemfile.lock
8
5
  tmp
9
-
10
- # built docs
11
6
  .yardoc
12
7
  doc
13
-
14
- # built gems
15
8
  pkg
16
- *.gem
9
+ *.gem
@@ -0,0 +1 @@
1
+ 1.9.3@orm_adatper-sequel
@@ -0,0 +1,21 @@
1
+ ## 0.1.1 (unreleased)
2
+
3
+ ## 0.1.0 (2013-03-19)
4
+
5
+ * History.txt -> CHANGELOG.md
6
+
7
+ * Update LICENSE and README.md
8
+
9
+ * Add support for orm_adapter 0.4.0. Pull request by [rosenfeld](https://github.com/rosenfeld).
10
+
11
+ ## 0.0.3 (2011-05-28)
12
+
13
+ * Allow condition keys to be strings (for Devise compat.). Pull request by [mooman](https://github.com/mooman).
14
+
15
+ ## 0.0.2 (2011-01-14)
16
+
17
+ * Use Sequel [Subclasses plugin](http://sequel.rubyforge.org/rdoc-plugins/classes/Sequel/Plugins/Subclasses.html) to track descendents. Suggested by [mooman](https://github.com/mooman).
18
+
19
+ ## 0.0.1 (2011-01-09)
20
+
21
+ * Initial release [Don Morrison](https://github.com/elskwid).
data/LICENSE CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2010 Don Morrison (elskwid)
1
+ Copyright (c) 2011-2013 Don Morrison (elskwid)
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining
4
4
  a copy of this software and associated documentation files (the
data/README.md CHANGED
@@ -1,27 +1,71 @@
1
- ORM Adapter - Sequel Adapter
2
- ============================
1
+ # ORM Adapter - Sequel Adapter
3
2
 
4
- Adds the Sequel ORM adapter to the ORM Adapter project
3
+ ## Description
5
4
 
6
- gem install orm_adapter-sequel
5
+ Adds the Sequel ORM adapter to the ORM Adapter project.
7
6
 
8
- ORM Adapter
9
- -----------
7
+ ## Requirements
10
8
 
11
- For more information see the excellent [orm_adapter](http://github.com/ianwhite/orm_adapter)
9
+ * [ActiveModel >= 3.0.0](https://github.com/rails/rails/tree/master/activemodel)
10
+ * [orm_adapter >= 0.4.0](https://github.com/ianwhite/orm_adapter)
11
+ * [Sequel >= 3.18.0](https://github.com/jeremyevans/sequel)
12
12
 
13
- Development / Testing
14
- -------------------
13
+ This gem has been tested against Ruby 1.9.3.
15
14
 
16
- A Rake task is available to get the latest orm_adapter specs:
15
+ ## Installation
17
16
 
18
- rake update_orm_specs
17
+ Add this line to your application's Gemfile:
18
+
19
+ ```ruby
20
+ gem "orm_adapter-sequel"
21
+ ```
22
+
23
+ And then execute:
24
+
25
+ ```
26
+ $ bundle
27
+ ```
28
+
29
+ Or install it yourself as:
30
+
31
+ ```
32
+ $ gem install orm_adapter-sequel
33
+ ```
34
+
35
+ ## ORM Adapter
36
+
37
+ > "Provides a single point of entry for popular ruby ORMs. Its target audience is gem authors who want to support more than one ORM."
38
+
39
+ For more information see the [orm_adapter project](http://github.com/ianwhite/orm_adapter).
40
+
41
+ ## Development / Testing
42
+
43
+ This project is tested against `orm_adapter` to make sure it works as advertised. A Rake task is available to get the latest orm_adapter specs. It will checkout the project to a temporary directory and copy over the specs needed to run.
44
+
45
+ ```
46
+ $ rake update_orm_specs
47
+ ```
19
48
 
20
49
  To run the tests:
21
50
 
22
- rake spec
51
+ ```
52
+ $ rake spec
53
+ ```
54
+
55
+ ## Contributing
56
+
57
+ 1. [Fork it](https://github.com/elskwid/orm_adapter-sequel/fork_select)
58
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
59
+ 3. Commit your changes (`git commit -am 'Added some feature'`)
60
+ 4. Push to the branch (`git push origin my-new-feature`)
61
+ 5. [Create a Pull Request](https://github.com/elskwid/orm_adapter-sequel/pull/new)
62
+
63
+ ## Contributors
64
+
65
+ * Rachot Moragraan [(mooman)](https://github.com/mooman)
66
+ * Rodrigo Rosenfeld Rosas [(rosenfeld)](https://github.com/rosenfeld)
23
67
 
24
- Copyright
25
- ---------
68
+ ## License
26
69
 
27
- Copyright (c) 2011 Don Morrison (elskwid). See LICENSE for details.
70
+ * Freely distributable and licensed under the MIT license.
71
+ * Copyright (c) 2011-2013 Don Morrison ([elskwid](https://github.com/elskwid)). See LICENSE for details.
@@ -59,7 +59,7 @@ class Sequel::Model
59
59
  #
60
60
  # Sequel: #.order doesn't like an array hence the *
61
61
  def find_first(options)
62
- conditions, order = extract_conditions_and_order!(options)
62
+ conditions, order = extract_conditions!(options)
63
63
  klass.filter(conditions_to_hash(conditions)).order(*order_clause(order)).first
64
64
  end
65
65
 
@@ -68,7 +68,7 @@ class Sequel::Model
68
68
  #
69
69
  # Sequel: #.order doesn't like an array hence the *
70
70
  def find_all(options)
71
- conditions, order = extract_conditions_and_order!(options)
71
+ conditions, order = extract_conditions!(options)
72
72
  klass.filter(conditions_to_hash(conditions)).order(*order_clause(order)).all
73
73
  end
74
74
 
@@ -1,3 +1,3 @@
1
1
  module OrmAdapterSequel
2
- VERSION = "0.0.3"
3
- end
2
+ VERSION = "0.1.0"
3
+ end
@@ -19,7 +19,7 @@ Gem::Specification.new do |s|
19
19
  s.require_paths = ["lib"]
20
20
 
21
21
  s.add_dependency "activemodel", ">= 3.0.0"
22
- s.add_dependency "orm_adapter"
22
+ s.add_dependency "orm_adapter", ">= 0.4.0"
23
23
  s.add_dependency "sequel", ">= 3.18.0"
24
24
 
25
25
  s.add_development_dependency "bundler", ">= 1.0.0"
@@ -28,4 +28,4 @@ Gem::Specification.new do |s|
28
28
  s.add_development_dependency "rspec", ">= 2.4.0"
29
29
  s.add_development_dependency "sqlite3-ruby", ">= 1.3.2"
30
30
  s.add_development_dependency "yard", ">= 0.6.0"
31
- end
31
+ end
metadata CHANGED
@@ -1,177 +1,170 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: orm_adapter-sequel
3
- version: !ruby/object:Gem::Version
4
- hash: 25
5
- prerelease: false
6
- segments:
7
- - 0
8
- - 0
9
- - 3
10
- version: 0.0.3
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ prerelease:
11
6
  platform: ruby
12
- authors:
7
+ authors:
13
8
  - Don Morrison
14
9
  autorequire:
15
10
  bindir: bin
16
11
  cert_chain: []
17
-
18
- date: 2011-05-28 00:00:00 -07:00
19
- default_executable:
20
- dependencies:
21
- - !ruby/object:Gem::Dependency
12
+ date: 2013-03-20 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
22
15
  name: activemodel
23
- prerelease: false
24
- requirement: &id001 !ruby/object:Gem::Requirement
25
- none: false
26
- requirements:
27
- - - ">="
28
- - !ruby/object:Gem::Version
29
- hash: 7
30
- segments:
31
- - 3
32
- - 0
33
- - 0
16
+ requirement: !ruby/object:Gem::Requirement
17
+ none: false
18
+ requirements:
19
+ - - ! '>='
20
+ - !ruby/object:Gem::Version
34
21
  version: 3.0.0
35
22
  type: :runtime
36
- version_requirements: *id001
37
- - !ruby/object:Gem::Dependency
38
- name: orm_adapter
39
23
  prerelease: false
40
- requirement: &id002 !ruby/object:Gem::Requirement
41
- none: false
42
- requirements:
43
- - - ">="
44
- - !ruby/object:Gem::Version
45
- hash: 3
46
- segments:
47
- - 0
48
- version: "0"
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ! '>='
28
+ - !ruby/object:Gem::Version
29
+ version: 3.0.0
30
+ - !ruby/object:Gem::Dependency
31
+ name: orm_adapter
32
+ requirement: !ruby/object:Gem::Requirement
33
+ none: false
34
+ requirements:
35
+ - - ! '>='
36
+ - !ruby/object:Gem::Version
37
+ version: 0.4.0
49
38
  type: :runtime
50
- version_requirements: *id002
51
- - !ruby/object:Gem::Dependency
52
- name: sequel
53
39
  prerelease: false
54
- requirement: &id003 !ruby/object:Gem::Requirement
55
- none: false
56
- requirements:
57
- - - ">="
58
- - !ruby/object:Gem::Version
59
- hash: 79
60
- segments:
61
- - 3
62
- - 18
63
- - 0
40
+ version_requirements: !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - ! '>='
44
+ - !ruby/object:Gem::Version
45
+ version: 0.4.0
46
+ - !ruby/object:Gem::Dependency
47
+ name: sequel
48
+ requirement: !ruby/object:Gem::Requirement
49
+ none: false
50
+ requirements:
51
+ - - ! '>='
52
+ - !ruby/object:Gem::Version
64
53
  version: 3.18.0
65
54
  type: :runtime
66
- version_requirements: *id003
67
- - !ruby/object:Gem::Dependency
68
- name: bundler
69
55
  prerelease: false
70
- requirement: &id004 !ruby/object:Gem::Requirement
71
- none: false
72
- requirements:
73
- - - ">="
74
- - !ruby/object:Gem::Version
75
- hash: 23
76
- segments:
77
- - 1
78
- - 0
79
- - 0
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - ! '>='
60
+ - !ruby/object:Gem::Version
61
+ version: 3.18.0
62
+ - !ruby/object:Gem::Dependency
63
+ name: bundler
64
+ requirement: !ruby/object:Gem::Requirement
65
+ none: false
66
+ requirements:
67
+ - - ! '>='
68
+ - !ruby/object:Gem::Version
80
69
  version: 1.0.0
81
70
  type: :development
82
- version_requirements: *id004
83
- - !ruby/object:Gem::Dependency
84
- name: git
85
71
  prerelease: false
86
- requirement: &id005 !ruby/object:Gem::Requirement
87
- none: false
88
- requirements:
89
- - - ">="
90
- - !ruby/object:Gem::Version
91
- hash: 21
92
- segments:
93
- - 1
94
- - 2
95
- - 5
72
+ version_requirements: !ruby/object:Gem::Requirement
73
+ none: false
74
+ requirements:
75
+ - - ! '>='
76
+ - !ruby/object:Gem::Version
77
+ version: 1.0.0
78
+ - !ruby/object:Gem::Dependency
79
+ name: git
80
+ requirement: !ruby/object:Gem::Requirement
81
+ none: false
82
+ requirements:
83
+ - - ! '>='
84
+ - !ruby/object:Gem::Version
96
85
  version: 1.2.5
97
86
  type: :development
98
- version_requirements: *id005
99
- - !ruby/object:Gem::Dependency
100
- name: rake
101
87
  prerelease: false
102
- requirement: &id006 !ruby/object:Gem::Requirement
103
- none: false
104
- requirements:
105
- - - ">="
106
- - !ruby/object:Gem::Version
107
- hash: 49
108
- segments:
109
- - 0
110
- - 8
111
- - 7
88
+ version_requirements: !ruby/object:Gem::Requirement
89
+ none: false
90
+ requirements:
91
+ - - ! '>='
92
+ - !ruby/object:Gem::Version
93
+ version: 1.2.5
94
+ - !ruby/object:Gem::Dependency
95
+ name: rake
96
+ requirement: !ruby/object:Gem::Requirement
97
+ none: false
98
+ requirements:
99
+ - - ! '>='
100
+ - !ruby/object:Gem::Version
112
101
  version: 0.8.7
113
102
  type: :development
114
- version_requirements: *id006
115
- - !ruby/object:Gem::Dependency
116
- name: rspec
117
103
  prerelease: false
118
- requirement: &id007 !ruby/object:Gem::Requirement
119
- none: false
120
- requirements:
121
- - - ">="
122
- - !ruby/object:Gem::Version
123
- hash: 31
124
- segments:
125
- - 2
126
- - 4
127
- - 0
104
+ version_requirements: !ruby/object:Gem::Requirement
105
+ none: false
106
+ requirements:
107
+ - - ! '>='
108
+ - !ruby/object:Gem::Version
109
+ version: 0.8.7
110
+ - !ruby/object:Gem::Dependency
111
+ name: rspec
112
+ requirement: !ruby/object:Gem::Requirement
113
+ none: false
114
+ requirements:
115
+ - - ! '>='
116
+ - !ruby/object:Gem::Version
128
117
  version: 2.4.0
129
118
  type: :development
130
- version_requirements: *id007
131
- - !ruby/object:Gem::Dependency
132
- name: sqlite3-ruby
133
119
  prerelease: false
134
- requirement: &id008 !ruby/object:Gem::Requirement
135
- none: false
136
- requirements:
137
- - - ">="
138
- - !ruby/object:Gem::Version
139
- hash: 31
140
- segments:
141
- - 1
142
- - 3
143
- - 2
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ none: false
122
+ requirements:
123
+ - - ! '>='
124
+ - !ruby/object:Gem::Version
125
+ version: 2.4.0
126
+ - !ruby/object:Gem::Dependency
127
+ name: sqlite3-ruby
128
+ requirement: !ruby/object:Gem::Requirement
129
+ none: false
130
+ requirements:
131
+ - - ! '>='
132
+ - !ruby/object:Gem::Version
144
133
  version: 1.3.2
145
134
  type: :development
146
- version_requirements: *id008
147
- - !ruby/object:Gem::Dependency
148
- name: yard
149
135
  prerelease: false
150
- requirement: &id009 !ruby/object:Gem::Requirement
151
- none: false
152
- requirements:
153
- - - ">="
154
- - !ruby/object:Gem::Version
155
- hash: 7
156
- segments:
157
- - 0
158
- - 6
159
- - 0
136
+ version_requirements: !ruby/object:Gem::Requirement
137
+ none: false
138
+ requirements:
139
+ - - ! '>='
140
+ - !ruby/object:Gem::Version
141
+ version: 1.3.2
142
+ - !ruby/object:Gem::Dependency
143
+ name: yard
144
+ requirement: !ruby/object:Gem::Requirement
145
+ none: false
146
+ requirements:
147
+ - - ! '>='
148
+ - !ruby/object:Gem::Version
160
149
  version: 0.6.0
161
150
  type: :development
162
- version_requirements: *id009
151
+ prerelease: false
152
+ version_requirements: !ruby/object:Gem::Requirement
153
+ none: false
154
+ requirements:
155
+ - - ! '>='
156
+ - !ruby/object:Gem::Version
157
+ version: 0.6.0
163
158
  description: Adds Sequel ORM adapter to the orm_adapter project
164
159
  email: elskwid@gmail.com
165
160
  executables: []
166
-
167
161
  extensions: []
168
-
169
162
  extra_rdoc_files: []
170
-
171
- files:
163
+ files:
172
164
  - .gitignore
165
+ - .ruby-version
166
+ - CHANGELOG.md
173
167
  - Gemfile
174
- - History.txt
175
168
  - LICENSE
176
169
  - README.md
177
170
  - Rakefile
@@ -182,43 +175,32 @@ files:
182
175
  - spec/example_app_shared.rb
183
176
  - spec/sequel_spec.rb
184
177
  - spec/spec_helper.rb
185
- has_rdoc: true
186
178
  homepage: http://github.com/elskwid/orm_adapter-sequel
187
179
  licenses: []
188
-
189
180
  post_install_message:
190
181
  rdoc_options: []
191
-
192
- require_paths:
182
+ require_paths:
193
183
  - lib
194
- required_ruby_version: !ruby/object:Gem::Requirement
184
+ required_ruby_version: !ruby/object:Gem::Requirement
195
185
  none: false
196
- requirements:
197
- - - ">="
198
- - !ruby/object:Gem::Version
199
- hash: 3
200
- segments:
201
- - 0
202
- version: "0"
203
- required_rubygems_version: !ruby/object:Gem::Requirement
186
+ requirements:
187
+ - - ! '>='
188
+ - !ruby/object:Gem::Version
189
+ version: '0'
190
+ required_rubygems_version: !ruby/object:Gem::Requirement
204
191
  none: false
205
- requirements:
206
- - - ">="
207
- - !ruby/object:Gem::Version
208
- hash: 23
209
- segments:
210
- - 1
211
- - 3
212
- - 6
192
+ requirements:
193
+ - - ! '>='
194
+ - !ruby/object:Gem::Version
213
195
  version: 1.3.6
214
196
  requirements: []
215
-
216
197
  rubyforge_project: orm_adapter-sequel
217
- rubygems_version: 1.3.7
198
+ rubygems_version: 1.8.24
218
199
  signing_key:
219
200
  specification_version: 3
220
- summary: Adds sequel adapter to orm_adapter which provides a single point of entry for using basic features of popular ruby ORMs.
221
- test_files:
201
+ summary: Adds sequel adapter to orm_adapter which provides a single point of entry
202
+ for using basic features of popular ruby ORMs.
203
+ test_files:
222
204
  - spec/example_app_shared.rb
223
205
  - spec/sequel_spec.rb
224
206
  - spec/spec_helper.rb
@@ -1,14 +0,0 @@
1
- == 0.0.3 (2011-05-28)
2
-
3
- * Allow condition keys to be strings (for Devise compat.)
4
- Pull request by mooman [https://github.com/mooman]
5
-
6
- == 0.0.2 (2011-01-14)
7
-
8
- * Use Sequel Subclasses plugin to track descendents
9
- http://sequel.rubyforge.org/rdoc-plugins/classes/Sequel/Plugins/Subclasses.html
10
- Suggested by mooman [https://github.com/mooman]
11
-
12
- == 0.0.1 (2011-01-09)
13
-
14
- * Initial release [Don Morrison]