crate_ruby 0.0.6 → 0.0.7
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 +13 -5
- data/CONTRIBUTING.rst +7 -5
- data/DEVELOP.md +13 -0
- data/history.txt +5 -2
- data/lib/crate_ruby/client.rb +4 -3
- data/lib/crate_ruby/version.rb +1 -1
- metadata +8 -7
checksums.yaml
CHANGED
@@ -1,7 +1,15 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
|
2
|
+
!binary "U0hBMQ==":
|
3
|
+
metadata.gz: !binary |-
|
4
|
+
YjcwMDRlZDFjZmI1YzcxZDMyOGRkNTFjNWZkNWRiY2Q4OTA0ZGIxMA==
|
5
|
+
data.tar.gz: !binary |-
|
6
|
+
Zjg3ZjYzMTgwNWI2OTBmZjFkYzhkMzhmYzE4YTBhZDk2Yzk5ZTc1NQ==
|
5
7
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
|
8
|
+
metadata.gz: !binary |-
|
9
|
+
YzAwMjNlN2I2OGMxOGI2MTM4ZTUyYjE4NmRiYTc5MjQ4YTg3Y2YxY2QxZTY4
|
10
|
+
MTVjMjU5OTFlMDFmMWM2OGU3NzI0ZTE3MDg1MWYyNGRhOTMyOWNhYzc3YjVj
|
11
|
+
YmQyMjc4YmE2MTRjMjYwZTZiMDRhMjhmYzc3YTdhNmI4MmUxMTM=
|
12
|
+
data.tar.gz: !binary |-
|
13
|
+
MDNiMDQ2ZDdlODYzNDAzMDc1YzNiZWZlMzQ1MzI5M2NkMTdjYjNjMTYxMWI5
|
14
|
+
NmU5ODEwZWVlMjczYzE1ZTFmZDY1MThiMWE2OTAxNGI2ODlmMzUxZjJjYmQw
|
15
|
+
NjAyMTczYTM1Y2MwNzdlNDJkMTU1MWYzNzg4ZTdlZmU2ODI4NmQ=
|
data/CONTRIBUTING.rst
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
Contributing to Crate Ruby
|
2
2
|
==========================
|
3
3
|
|
4
|
-
Thanks for considering contributing to
|
4
|
+
Thanks for considering contributing to the Crate Data Ruby library.
|
5
5
|
|
6
6
|
|
7
7
|
Reporting an issue
|
@@ -23,8 +23,9 @@ Reporting an issue
|
|
23
23
|
Pull requests
|
24
24
|
-------------
|
25
25
|
|
26
|
-
Before we can accept any pull requests to
|
27
|
-
our CLA_. Once that is done, we suggest to
|
26
|
+
Before we can accept any pull requests to the Crate Data Ruby library
|
27
|
+
we need you to agree to our CLA_. Once that is done, we suggest to
|
28
|
+
continue as follows:
|
28
29
|
|
29
30
|
- Add an issue on Github and let us know that you're working on something.
|
30
31
|
|
@@ -35,9 +36,11 @@ our CLA_. Once that is done, we suggest to continue as follows:
|
|
35
36
|
- Be descriptive in your PR and commit messages. What is it for, why is it
|
36
37
|
needed, etc.
|
37
38
|
|
39
|
+
- Make sure the tests pass.
|
40
|
+
|
38
41
|
- Squash related commits
|
39
42
|
|
40
|
-
.. _CLA: https://crate.io/contribute/
|
43
|
+
.. _CLA: https://crate.io/community/contribute/
|
41
44
|
|
42
45
|
|
43
46
|
Rebase
|
@@ -88,4 +91,3 @@ fixup commits and mark them to squash. But in order for that to work the
|
|
88
91
|
``autosquash`` setting has to be enabled in the ``.gitconfig``::
|
89
92
|
|
90
93
|
git config --global rebase.autosquash true
|
91
|
-
|
data/DEVELOP.md
ADDED
@@ -0,0 +1,13 @@
|
|
1
|
+
# Release Process
|
2
|
+
|
3
|
+
Business as usual, but in case you forgot, here it is.
|
4
|
+
|
5
|
+
* update ``CrateRuby.version`` in ``lib/crate_ruby/version.rb``
|
6
|
+
* update history.txt to reflect the changes of this release
|
7
|
+
* Do the traditional trinity of:
|
8
|
+
|
9
|
+
```ruby
|
10
|
+
gem update --system
|
11
|
+
gem build crate_ruby.gemspec
|
12
|
+
gem push crate_ruby-<version>.gem
|
13
|
+
```
|
data/history.txt
CHANGED
data/lib/crate_ruby/client.rb
CHANGED
@@ -181,9 +181,10 @@ module CrateRuby
|
|
181
181
|
|
182
182
|
|
183
183
|
def insert(table_name, attributes)
|
184
|
-
vals = attributes.values
|
185
|
-
|
186
|
-
|
184
|
+
vals = attributes.values
|
185
|
+
binds = vals.count.times.map {|i| "$#{i+1}"}.join(',')
|
186
|
+
stmt = %Q{INSERT INTO "#{table_name}" (#{attributes.keys.join(', ')}) VALUES(#{binds})}
|
187
|
+
execute(stmt, vals)
|
187
188
|
end
|
188
189
|
|
189
190
|
# Crate is eventually consistent, If you don't query by primary key,
|
data/lib/crate_ruby/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: crate_ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Christoph Klocker
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2014-
|
12
|
+
date: 2014-09-25 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: bundler
|
@@ -29,14 +29,14 @@ dependencies:
|
|
29
29
|
name: rake
|
30
30
|
requirement: !ruby/object:Gem::Requirement
|
31
31
|
requirements:
|
32
|
-
- - '>='
|
32
|
+
- - ! '>='
|
33
33
|
- !ruby/object:Gem::Version
|
34
34
|
version: '0'
|
35
35
|
type: :development
|
36
36
|
prerelease: false
|
37
37
|
version_requirements: !ruby/object:Gem::Requirement
|
38
38
|
requirements:
|
39
|
-
- - '>='
|
39
|
+
- - ! '>='
|
40
40
|
- !ruby/object:Gem::Version
|
41
41
|
version: '0'
|
42
42
|
- !ruby/object:Gem::Dependency
|
@@ -64,6 +64,7 @@ files:
|
|
64
64
|
- .gitignore
|
65
65
|
- .travis.yml
|
66
66
|
- CONTRIBUTING.rst
|
67
|
+
- DEVELOP.md
|
67
68
|
- Gemfile
|
68
69
|
- LICENSE
|
69
70
|
- NOTICE
|
@@ -95,17 +96,17 @@ require_paths:
|
|
95
96
|
- lib
|
96
97
|
required_ruby_version: !ruby/object:Gem::Requirement
|
97
98
|
requirements:
|
98
|
-
- - '>='
|
99
|
+
- - ! '>='
|
99
100
|
- !ruby/object:Gem::Version
|
100
101
|
version: '0'
|
101
102
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
102
103
|
requirements:
|
103
|
-
- - '>='
|
104
|
+
- - ! '>='
|
104
105
|
- !ruby/object:Gem::Version
|
105
106
|
version: '0'
|
106
107
|
requirements: []
|
107
108
|
rubyforge_project:
|
108
|
-
rubygems_version: 2.
|
109
|
+
rubygems_version: 2.4.1
|
109
110
|
signing_key:
|
110
111
|
specification_version: 4
|
111
112
|
summary: A simple interface to Crate Data.
|