lotus-postgres 0.1.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.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 2d878113df214015af0432c6a631185448f70200
4
+ data.tar.gz: 1578074c744cc6698bf507e5cda14ac7c344586f
5
+ SHA512:
6
+ metadata.gz: 0cb9f344d163df1e487f927958545891222d47a76bcaf7761072904635e7c284e4b1e7ddf3585d380b05cf3cf1b6706bc22f2f20260c752e16bce7868481c57e
7
+ data.tar.gz: cdbcdd7103eeb59a81046ca25bc37ccb0e1dd037360ff666df8ee86a6e29a2149990f8fb1dfcbfeb77dbb9336f27db6155d7ff94e375240b16a3f1806aca5ca7
@@ -0,0 +1,22 @@
1
+ Copyright © 2015 Jan Lelis
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,3 @@
1
+ # Lotus Postgres Adapter
2
+
3
+ Not very much too see, yet
@@ -0,0 +1 @@
1
+ require 'lotus/postgres'
@@ -0,0 +1,14 @@
1
+ require 'lotus/model/adapters/sql_adapter'
2
+
3
+ module Lotus
4
+ module Model
5
+ module Adapters
6
+ class PostgresAdapter < SqlAdapter
7
+ def initialize(mapper, uri)
8
+ super
9
+ @connection.extension :pg_array
10
+ end
11
+ end
12
+ end
13
+ end
14
+ end
@@ -0,0 +1,9 @@
1
+ require_relative 'postgres/version'
2
+ require_relative 'model/adapters/postgres_adapter'
3
+
4
+
5
+ require 'lotus/model/mapping/coercions'
6
+
7
+ def Lotus::Model::Mapping::Coercions.Array(arg)
8
+ Sequel.pg_array(super) unless arg.nil?
9
+ end
@@ -0,0 +1,5 @@
1
+ module Lotus
2
+ module Postgres
3
+ VERSION = '0.1.0'.freeze
4
+ end
5
+ end
@@ -0,0 +1,27 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'lotus/postgres/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = 'lotus-postgres'
8
+ spec.version = Lotus::Postgres::VERSION
9
+ spec.authors = ['Jan Lelis']
10
+ spec.email = ['mail@janlelis.de']
11
+ spec.summary = %q{PostgreSQL adapter for Lotus}
12
+ spec.description = %q{SQL adapter for Lotus with PostgreSQL specific additions}
13
+ spec.homepage = 'https://github.com/janlelis/lotus-postgres'
14
+ spec.license = 'MIT'
15
+
16
+ spec.files = `git ls-files -z -- lib/* CHANGELOG.md EXAMPLE.md LICENSE.md README.md lotus-postgres.gemspec`.split("\x0")
17
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
18
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
+ spec.require_paths = ['lib']
20
+ spec.required_ruby_version = '>= 2.0.0'
21
+
22
+ spec.add_runtime_dependency 'lotus-model', '~> 0.2'
23
+
24
+ spec.add_development_dependency 'bundler', '~> 1.6'
25
+ spec.add_development_dependency 'minitest', '~> 5'
26
+ spec.add_development_dependency 'rake', '~> 10'
27
+ end
metadata ADDED
@@ -0,0 +1,108 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: lotus-postgres
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Jan Lelis
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2015-03-15 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: lotus-model
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '0.2'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '0.2'
27
+ - !ruby/object:Gem::Dependency
28
+ name: bundler
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '1.6'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '1.6'
41
+ - !ruby/object:Gem::Dependency
42
+ name: minitest
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '5'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '5'
55
+ - !ruby/object:Gem::Dependency
56
+ name: rake
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
60
+ - !ruby/object:Gem::Version
61
+ version: '10'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: '10'
69
+ description: SQL adapter for Lotus with PostgreSQL specific additions
70
+ email:
71
+ - mail@janlelis.de
72
+ executables: []
73
+ extensions: []
74
+ extra_rdoc_files: []
75
+ files:
76
+ - LICENSE.md
77
+ - README.md
78
+ - lib/lotus-postgres.rb
79
+ - lib/lotus/model/adapters/postgres_adapter.rb
80
+ - lib/lotus/postgres.rb
81
+ - lib/lotus/postgres/version.rb
82
+ - lotus-postgres.gemspec
83
+ homepage: https://github.com/janlelis/lotus-postgres
84
+ licenses:
85
+ - MIT
86
+ metadata: {}
87
+ post_install_message:
88
+ rdoc_options: []
89
+ require_paths:
90
+ - lib
91
+ required_ruby_version: !ruby/object:Gem::Requirement
92
+ requirements:
93
+ - - ">="
94
+ - !ruby/object:Gem::Version
95
+ version: 2.0.0
96
+ required_rubygems_version: !ruby/object:Gem::Requirement
97
+ requirements:
98
+ - - ">="
99
+ - !ruby/object:Gem::Version
100
+ version: '0'
101
+ requirements: []
102
+ rubyforge_project:
103
+ rubygems_version: 2.4.5
104
+ signing_key:
105
+ specification_version: 4
106
+ summary: PostgreSQL adapter for Lotus
107
+ test_files: []
108
+ has_rdoc: