embulk-parser-json 0.0.4 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/embulk-parser-json.gemspec +1 -1
- data/lib/embulk/parser/jsonpath.rb +7 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4a50a899523c149951f3bb4b67f917ed7be074d0
|
4
|
+
data.tar.gz: eff2a6db83ee9af56a4588c1951b28093732094d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 66d5ab493130ac329c0a2790c2803d294f9860e8949a1c6706cae2b8f7cffca272b2cf5f97bf3468ce24c09d7b2ee5207d17b707d5551214b2f285b318cd5ca3
|
7
|
+
data.tar.gz: 3f7f230abb7b10dc89a6385732ed5108e236328d4950e0a6b8518bdad59edb86f3add74a83e39e9762c69eb12de808fd7af16b6579ea677430d68c36b66e31a6
|
data/embulk-parser-json.gemspec
CHANGED
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
4
4
|
|
5
5
|
Gem::Specification.new do |spec|
|
6
6
|
spec.name = "embulk-parser-json"
|
7
|
-
spec.version = "0.0.
|
7
|
+
spec.version = "0.0.5"
|
8
8
|
spec.authors = ["Takuma kanari"]
|
9
9
|
spec.email = ["chemtrails.t@gmail.com"]
|
10
10
|
spec.summary = %q{Embulk parser plugin for json with jsonpath}
|
@@ -47,7 +47,9 @@ module Embulk
|
|
47
47
|
when "json"
|
48
48
|
val
|
49
49
|
when "boolean"
|
50
|
-
if
|
50
|
+
if kind_of_boolean?(val)
|
51
|
+
val
|
52
|
+
elsif val.nil? || val.empty?
|
51
53
|
nil
|
52
54
|
elsif val.kind_of?(String)
|
53
55
|
["yes", "true", "1"].include?(val.downcase)
|
@@ -63,6 +65,10 @@ module Embulk
|
|
63
65
|
end
|
64
66
|
end
|
65
67
|
end
|
68
|
+
|
69
|
+
def kind_of_boolean?(val)
|
70
|
+
val.kind_of?(TrueClass) || val.kind_of?(FalseClass)
|
71
|
+
end
|
66
72
|
end
|
67
73
|
end
|
68
74
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: embulk-parser-json
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Takuma kanari
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2017-01-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: jsonpath
|
@@ -87,7 +87,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
87
87
|
version: '0'
|
88
88
|
requirements: []
|
89
89
|
rubyforge_project:
|
90
|
-
rubygems_version: 2.5
|
90
|
+
rubygems_version: 2.4.5
|
91
91
|
signing_key:
|
92
92
|
specification_version: 4
|
93
93
|
summary: Embulk parser plugin for json with jsonpath
|