leanback 0.5.4 → 0.5.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +2 -12
- data/Gemfile +1 -1
- data/Gemfile.lock +37 -30
- data/README.md +9 -9
- data/VERSION +1 -1
- data/leanback.gemspec +32 -32
- metadata +17 -17
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dd67449e6948a89a886bcdcbc75a10fef0c9cb60
|
4
|
+
data.tar.gz: 84cbab2a4b09902174469a14df231624124aa783
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 42d3a30f27d741cc38a249fcd5fa453ecdf1cfd9c6b29683dde95f900719a0f6709460e61808acc701e7f4e528da135a8e776184ffde151ed613bdba67e8e6d8
|
7
|
+
data.tar.gz: f0ab5b1b81cb5df4e068f9b738e7182f3f9323a33e60c4168d9bb26b0332f3b907a855b22b25db638fe56f290e74c7d3aa11cdb32c5e749c2fa700efbddb0b82
|
data/.travis.yml
CHANGED
@@ -1,17 +1,7 @@
|
|
1
1
|
language: ruby
|
2
2
|
rvm:
|
3
|
-
- 2.
|
4
|
-
- 2.
|
5
|
-
- 2.1.1
|
6
|
-
- 1.9.3
|
7
|
-
- jruby-19mode # JRuby in 1.9 mode
|
8
|
-
|
9
|
-
matrix:
|
10
|
-
allow_failures:
|
11
|
-
- rvm: jruby-19mode # JRuby in 1.9 mode
|
12
|
-
- rvm: rbx
|
13
|
-
- rvm: 1.9.3
|
14
|
-
|
3
|
+
- 2.5.0
|
4
|
+
- 2.4.1
|
15
5
|
|
16
6
|
services:
|
17
7
|
- couchdb
|
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
@@ -2,46 +2,51 @@ GEM
|
|
2
2
|
remote: http://rubygems.org/
|
3
3
|
specs:
|
4
4
|
addressable (2.4.0)
|
5
|
-
builder (3.2.
|
5
|
+
builder (3.2.3)
|
6
6
|
coderay (1.1.1)
|
7
|
+
descendants_tracker (0.0.4)
|
8
|
+
thread_safe (~> 0.3, >= 0.3.1)
|
7
9
|
diff-lcs (1.2.5)
|
8
10
|
domain_name (0.5.20160309)
|
9
11
|
unf (>= 0.0.5, < 1.0.0)
|
10
|
-
faraday (0.
|
11
|
-
multipart-post (
|
12
|
+
faraday (0.9.2)
|
13
|
+
multipart-post (>= 1.2, < 3)
|
12
14
|
git (1.3.0)
|
13
|
-
github_api (0.
|
14
|
-
addressable
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
oauth2
|
20
|
-
hashie (3.
|
21
|
-
highline (1.7.
|
15
|
+
github_api (0.16.0)
|
16
|
+
addressable (~> 2.4.0)
|
17
|
+
descendants_tracker (~> 0.0.4)
|
18
|
+
faraday (~> 0.8, < 0.10)
|
19
|
+
hashie (>= 3.4)
|
20
|
+
mime-types (>= 1.16, < 3.0)
|
21
|
+
oauth2 (~> 1.0)
|
22
|
+
hashie (3.5.7)
|
23
|
+
highline (1.7.10)
|
22
24
|
http-cookie (1.0.2)
|
23
25
|
domain_name (~> 0.5)
|
24
|
-
jeweler (
|
26
|
+
jeweler (2.3.9)
|
25
27
|
builder
|
26
|
-
bundler
|
28
|
+
bundler
|
27
29
|
git (>= 1.2.5)
|
28
|
-
github_api (
|
30
|
+
github_api (~> 0.16.0)
|
29
31
|
highline (>= 1.6.15)
|
30
|
-
nokogiri (
|
32
|
+
nokogiri (>= 1.5.10)
|
33
|
+
psych
|
31
34
|
rake
|
32
35
|
rdoc
|
33
|
-
|
34
|
-
jwt (1.5.
|
36
|
+
semver2
|
37
|
+
jwt (1.5.6)
|
35
38
|
method_source (0.8.2)
|
36
39
|
mime-types (2.99.1)
|
40
|
+
mini_portile2 (2.3.0)
|
37
41
|
multi_json (1.11.2)
|
38
|
-
multi_xml (0.
|
39
|
-
multipart-post (
|
42
|
+
multi_xml (0.6.0)
|
43
|
+
multipart-post (2.0.0)
|
40
44
|
netrc (0.11.0)
|
41
|
-
nokogiri (1.
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
+
nokogiri (1.8.2)
|
46
|
+
mini_portile2 (~> 2.3.0)
|
47
|
+
oauth2 (1.4.0)
|
48
|
+
faraday (>= 0.8, < 0.13)
|
49
|
+
jwt (~> 1.0)
|
45
50
|
multi_json (~> 1.3)
|
46
51
|
multi_xml (~> 0.5)
|
47
52
|
rack (>= 1.2, < 3)
|
@@ -49,10 +54,10 @@ GEM
|
|
49
54
|
coderay (~> 1.1.0)
|
50
55
|
method_source (~> 0.8.1)
|
51
56
|
slop (~> 3.4)
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
57
|
+
psych (3.0.2)
|
58
|
+
rack (2.0.4)
|
59
|
+
rake (12.3.0)
|
60
|
+
rdoc (6.0.1)
|
56
61
|
rest-client (1.8.0)
|
57
62
|
http-cookie (>= 1.0.2, < 2.0)
|
58
63
|
mime-types (>= 1.16, < 3.0)
|
@@ -70,7 +75,9 @@ GEM
|
|
70
75
|
diff-lcs (>= 1.2.0, < 2.0)
|
71
76
|
rspec-support (~> 3.4.0)
|
72
77
|
rspec-support (3.4.1)
|
78
|
+
semver2 (3.4.2)
|
73
79
|
slop (3.6.0)
|
80
|
+
thread_safe (0.3.6)
|
74
81
|
unf (0.1.4)
|
75
82
|
unf_ext
|
76
83
|
unf_ext (0.0.7.2)
|
@@ -80,11 +87,11 @@ PLATFORMS
|
|
80
87
|
|
81
88
|
DEPENDENCIES
|
82
89
|
bundler
|
83
|
-
jeweler (~>
|
90
|
+
jeweler (~> 2.3.7)
|
84
91
|
multi_json
|
85
92
|
pry
|
86
93
|
rest-client
|
87
94
|
rspec
|
88
95
|
|
89
96
|
BUNDLED WITH
|
90
|
-
1.
|
97
|
+
1.14.6
|
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
###Leanback
|
1
|
+
### Leanback
|
2
2
|
|
3
3
|
[![Build Status](https://travis-ci.org/obi-a/leanback.svg?branch=master)](https://travis-ci.org/obi-a/leanback)
|
4
4
|
[![Gem Version](https://badge.fury.io/rb/leanback.svg)](http://badge.fury.io/rb/leanback)
|
@@ -291,7 +291,7 @@ my_database.view("_design/gender_city", "people_by_gender_and_city", startkey: [
|
|
291
291
|
# :offset=>1,
|
292
292
|
# :rows=>[{:id=>"nancy", :key=>["female", "bronx", 25], :value=>nil}]}
|
293
293
|
```
|
294
|
-
###Dynamic Queries
|
294
|
+
### Dynamic Queries
|
295
295
|
Dynamic queries can be performed on documents using the where() helper method, example to fetch all documents that match the key/value pairs {city: "bronx", gender: "female"}
|
296
296
|
```ruby
|
297
297
|
my_database.where(city: "bronx", gender: "female")
|
@@ -373,8 +373,8 @@ And then query it with:
|
|
373
373
|
```
|
374
374
|
Subsequent method calls will simply query the view and return the documents. where() is just a convienient helper method.
|
375
375
|
|
376
|
-
###Security Object:
|
377
|
-
To set the security object for the database:
|
376
|
+
### Security Object:
|
377
|
+
Please note that this does not work with CouchDB 2, only works with CouchDB v1.6.1 and less. To set the security object for the database:
|
378
378
|
```ruby
|
379
379
|
security_settings = {
|
380
380
|
admins: {names: ["david"], roles: ["admin"]},
|
@@ -393,8 +393,8 @@ my_database.security_object
|
|
393
393
|
# :readers=>{:names=>["david"], :roles=>["admin"]}}
|
394
394
|
```
|
395
395
|
|
396
|
-
###CouchDB Configuration
|
397
|
-
CouchDB's configuration settings can be set using the set_config() method:
|
396
|
+
### CouchDB Configuration
|
397
|
+
Please note that this does not work with CouchDB 2, only works with CouchDB v1.6.1 and less. CouchDB's configuration settings can be set using the set_config() method:
|
398
398
|
```ruby
|
399
399
|
config = Leanback::Couchdb.new
|
400
400
|
config.set_config("section", "option", '"value"')
|
@@ -423,7 +423,7 @@ config.set_config("admins", username = "james", password = '"abc123"')
|
|
423
423
|
```
|
424
424
|
This will add a CouchDB admin with username james, and password abc123. If couchDB was in admin party mode, this would end the party.
|
425
425
|
|
426
|
-
##Exception handling
|
426
|
+
## Exception handling
|
427
427
|
For CouchDB errors Leanback raises a Leanback::Exception object. This object has a response attribute which is a hash that contains the details of the error response from CouchDB. See an example below
|
428
428
|
```ruby
|
429
429
|
begin
|
@@ -438,7 +438,7 @@ rescue Leanback::CouchdbException => e
|
|
438
438
|
end
|
439
439
|
```
|
440
440
|
|
441
|
-
##API Specification
|
441
|
+
## API Specification
|
442
442
|
|
443
443
|
```ruby
|
444
444
|
#JSON result keys are automatically symoblized:
|
@@ -492,7 +492,7 @@ c.get_config("couch_httpd_auth", "timeout")
|
|
492
492
|
c.delete_config("section", "option")
|
493
493
|
```
|
494
494
|
|
495
|
-
##Supported Rubies
|
495
|
+
## Supported Rubies
|
496
496
|
jruby-19mode, MRI 1.9.3 - 2.x
|
497
497
|
|
498
498
|
##License
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.5.
|
1
|
+
0.5.5
|
data/leanback.gemspec
CHANGED
@@ -1,19 +1,19 @@
|
|
1
1
|
# Generated by jeweler
|
2
2
|
# DO NOT EDIT THIS FILE DIRECTLY
|
3
|
-
# Instead, edit Jeweler::Tasks in
|
3
|
+
# Instead, edit Jeweler::Tasks in rakefile, and run 'rake gemspec'
|
4
4
|
# -*- encoding: utf-8 -*-
|
5
|
-
# stub: leanback 0.5.
|
5
|
+
# stub: leanback 0.5.5 ruby lib
|
6
6
|
|
7
7
|
Gem::Specification.new do |s|
|
8
|
-
s.name = "leanback"
|
9
|
-
s.version = "0.5.
|
8
|
+
s.name = "leanback".freeze
|
9
|
+
s.version = "0.5.5"
|
10
10
|
|
11
|
-
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
12
|
-
s.require_paths = ["lib"]
|
13
|
-
s.authors = ["Obi Akubue"]
|
14
|
-
s.date = "
|
15
|
-
s.description = "Simple Ruby interface to CouchDB"
|
16
|
-
s.email = "obioraakubue@yahoo.com"
|
11
|
+
s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
|
12
|
+
s.require_paths = ["lib".freeze]
|
13
|
+
s.authors = ["Obi Akubue".freeze]
|
14
|
+
s.date = "2018-02-10"
|
15
|
+
s.description = "Simple Ruby interface to CouchDB".freeze
|
16
|
+
s.email = "obioraakubue@yahoo.com".freeze
|
17
17
|
s.extra_rdoc_files = [
|
18
18
|
"LICENSE.txt",
|
19
19
|
"README.md"
|
@@ -32,36 +32,36 @@ Gem::Specification.new do |s|
|
|
32
32
|
"spec/leanback_spec.rb",
|
33
33
|
"spec/spec_base.rb"
|
34
34
|
]
|
35
|
-
s.homepage = "http://github.com/obi-a/leanback"
|
36
|
-
s.licenses = ["MIT"]
|
37
|
-
s.rubygems_version = "2.
|
38
|
-
s.summary = "Simple Ruby interface to CouchDB"
|
35
|
+
s.homepage = "http://github.com/obi-a/leanback".freeze
|
36
|
+
s.licenses = ["MIT".freeze]
|
37
|
+
s.rubygems_version = "2.6.6".freeze
|
38
|
+
s.summary = "Simple Ruby interface to CouchDB".freeze
|
39
39
|
|
40
40
|
if s.respond_to? :specification_version then
|
41
41
|
s.specification_version = 4
|
42
42
|
|
43
43
|
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
44
|
-
s.add_runtime_dependency(%q<rest-client
|
45
|
-
s.add_runtime_dependency(%q<multi_json
|
46
|
-
s.add_development_dependency(%q<pry
|
47
|
-
s.add_development_dependency(%q<bundler
|
48
|
-
s.add_development_dependency(%q<jeweler
|
49
|
-
s.add_development_dependency(%q<rspec
|
44
|
+
s.add_runtime_dependency(%q<rest-client>.freeze, [">= 0"])
|
45
|
+
s.add_runtime_dependency(%q<multi_json>.freeze, [">= 0"])
|
46
|
+
s.add_development_dependency(%q<pry>.freeze, [">= 0"])
|
47
|
+
s.add_development_dependency(%q<bundler>.freeze, [">= 0"])
|
48
|
+
s.add_development_dependency(%q<jeweler>.freeze, ["~> 2.3.7"])
|
49
|
+
s.add_development_dependency(%q<rspec>.freeze, [">= 0"])
|
50
50
|
else
|
51
|
-
s.add_dependency(%q<rest-client
|
52
|
-
s.add_dependency(%q<multi_json
|
53
|
-
s.add_dependency(%q<pry
|
54
|
-
s.add_dependency(%q<bundler
|
55
|
-
s.add_dependency(%q<jeweler
|
56
|
-
s.add_dependency(%q<rspec
|
51
|
+
s.add_dependency(%q<rest-client>.freeze, [">= 0"])
|
52
|
+
s.add_dependency(%q<multi_json>.freeze, [">= 0"])
|
53
|
+
s.add_dependency(%q<pry>.freeze, [">= 0"])
|
54
|
+
s.add_dependency(%q<bundler>.freeze, [">= 0"])
|
55
|
+
s.add_dependency(%q<jeweler>.freeze, ["~> 2.3.7"])
|
56
|
+
s.add_dependency(%q<rspec>.freeze, [">= 0"])
|
57
57
|
end
|
58
58
|
else
|
59
|
-
s.add_dependency(%q<rest-client
|
60
|
-
s.add_dependency(%q<multi_json
|
61
|
-
s.add_dependency(%q<pry
|
62
|
-
s.add_dependency(%q<bundler
|
63
|
-
s.add_dependency(%q<jeweler
|
64
|
-
s.add_dependency(%q<rspec
|
59
|
+
s.add_dependency(%q<rest-client>.freeze, [">= 0"])
|
60
|
+
s.add_dependency(%q<multi_json>.freeze, [">= 0"])
|
61
|
+
s.add_dependency(%q<pry>.freeze, [">= 0"])
|
62
|
+
s.add_dependency(%q<bundler>.freeze, [">= 0"])
|
63
|
+
s.add_dependency(%q<jeweler>.freeze, ["~> 2.3.7"])
|
64
|
+
s.add_dependency(%q<rspec>.freeze, [">= 0"])
|
65
65
|
end
|
66
66
|
end
|
67
67
|
|
metadata
CHANGED
@@ -1,99 +1,99 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: leanback
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Obi Akubue
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-02-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
|
-
name: rest-client
|
15
14
|
requirement: !ruby/object:Gem::Requirement
|
16
15
|
requirements:
|
17
16
|
- - ">="
|
18
17
|
- !ruby/object:Gem::Version
|
19
18
|
version: '0'
|
20
|
-
type: :runtime
|
21
19
|
prerelease: false
|
20
|
+
name: rest-client
|
22
21
|
version_requirements: !ruby/object:Gem::Requirement
|
23
22
|
requirements:
|
24
23
|
- - ">="
|
25
24
|
- !ruby/object:Gem::Version
|
26
25
|
version: '0'
|
26
|
+
type: :runtime
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
|
-
name: multi_json
|
29
28
|
requirement: !ruby/object:Gem::Requirement
|
30
29
|
requirements:
|
31
30
|
- - ">="
|
32
31
|
- !ruby/object:Gem::Version
|
33
32
|
version: '0'
|
34
|
-
type: :runtime
|
35
33
|
prerelease: false
|
34
|
+
name: multi_json
|
36
35
|
version_requirements: !ruby/object:Gem::Requirement
|
37
36
|
requirements:
|
38
37
|
- - ">="
|
39
38
|
- !ruby/object:Gem::Version
|
40
39
|
version: '0'
|
40
|
+
type: :runtime
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
|
-
name: pry
|
43
42
|
requirement: !ruby/object:Gem::Requirement
|
44
43
|
requirements:
|
45
44
|
- - ">="
|
46
45
|
- !ruby/object:Gem::Version
|
47
46
|
version: '0'
|
48
|
-
type: :development
|
49
47
|
prerelease: false
|
48
|
+
name: pry
|
50
49
|
version_requirements: !ruby/object:Gem::Requirement
|
51
50
|
requirements:
|
52
51
|
- - ">="
|
53
52
|
- !ruby/object:Gem::Version
|
54
53
|
version: '0'
|
54
|
+
type: :development
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
|
-
name: bundler
|
57
56
|
requirement: !ruby/object:Gem::Requirement
|
58
57
|
requirements:
|
59
58
|
- - ">="
|
60
59
|
- !ruby/object:Gem::Version
|
61
60
|
version: '0'
|
62
|
-
type: :development
|
63
61
|
prerelease: false
|
62
|
+
name: bundler
|
64
63
|
version_requirements: !ruby/object:Gem::Requirement
|
65
64
|
requirements:
|
66
65
|
- - ">="
|
67
66
|
- !ruby/object:Gem::Version
|
68
67
|
version: '0'
|
68
|
+
type: :development
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
|
-
name: jeweler
|
71
70
|
requirement: !ruby/object:Gem::Requirement
|
72
71
|
requirements:
|
73
72
|
- - "~>"
|
74
73
|
- !ruby/object:Gem::Version
|
75
|
-
version:
|
76
|
-
type: :development
|
74
|
+
version: 2.3.7
|
77
75
|
prerelease: false
|
76
|
+
name: jeweler
|
78
77
|
version_requirements: !ruby/object:Gem::Requirement
|
79
78
|
requirements:
|
80
79
|
- - "~>"
|
81
80
|
- !ruby/object:Gem::Version
|
82
|
-
version:
|
81
|
+
version: 2.3.7
|
82
|
+
type: :development
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
|
-
name: rspec
|
85
84
|
requirement: !ruby/object:Gem::Requirement
|
86
85
|
requirements:
|
87
86
|
- - ">="
|
88
87
|
- !ruby/object:Gem::Version
|
89
88
|
version: '0'
|
90
|
-
type: :development
|
91
89
|
prerelease: false
|
90
|
+
name: rspec
|
92
91
|
version_requirements: !ruby/object:Gem::Requirement
|
93
92
|
requirements:
|
94
93
|
- - ">="
|
95
94
|
- !ruby/object:Gem::Version
|
96
95
|
version: '0'
|
96
|
+
type: :development
|
97
97
|
description: Simple Ruby interface to CouchDB
|
98
98
|
email: obioraakubue@yahoo.com
|
99
99
|
executables: []
|
@@ -134,7 +134,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
134
134
|
version: '0'
|
135
135
|
requirements: []
|
136
136
|
rubyforge_project:
|
137
|
-
rubygems_version: 2.
|
137
|
+
rubygems_version: 2.6.6
|
138
138
|
signing_key:
|
139
139
|
specification_version: 4
|
140
140
|
summary: Simple Ruby interface to CouchDB
|