kmdata 0.0.5 → 0.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/kmdata +7 -2
- data/lib/kmdata/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ced116d2224b90c24b85f19da02691a8e078b8ad
|
4
|
+
data.tar.gz: 906d2dc3299b58f327e2d6008f637fe369bd5e5d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 827b476ca7893288a49577ab97916d45792fb409de00a66e633bca3817a47011a83998bcb8a90da94b4c00ff9ce3671b0ab1161964dd93012b584352063d97d0
|
7
|
+
data.tar.gz: 4f9a1e46cc0a417aa9f119daf8224e95a973f33f0ae6e88355c05a713a94a132f81d84a4a8cb00511c2842b1d0eb21c1ab3d3f5fd50290da12bee200037f237b
|
data/bin/kmdata
CHANGED
@@ -4,7 +4,8 @@ require 'kmdata'
|
|
4
4
|
require 'optparse'
|
5
5
|
require 'pry'
|
6
6
|
|
7
|
-
options = { model:
|
7
|
+
options = { model: "people", include: "addresses,phone_numbers" }
|
8
|
+
|
8
9
|
|
9
10
|
OptionParser.new do |opts|
|
10
11
|
opts.banner = "Usage: kmdata [query] [options]"
|
@@ -12,10 +13,14 @@ OptionParser.new do |opts|
|
|
12
13
|
opts.on("-m", "--model [MODEL]") do |m|
|
13
14
|
options[:model] = m
|
14
15
|
end
|
16
|
+
|
17
|
+
opts.on("-i", "--include [INCLUDE]") do |m|
|
18
|
+
options[:model] = m
|
19
|
+
end
|
15
20
|
end.parse!
|
16
21
|
|
17
22
|
if ARGV[0]
|
18
|
-
results = KMData.get(options[:model], q: ARGV[0])
|
23
|
+
results = KMData.get(options[:model], q: ARGV[0], include: options[:include])
|
19
24
|
|
20
25
|
if results.any?
|
21
26
|
results.each do |object|
|
data/lib/kmdata/version.rb
CHANGED