embulk-parser-xml 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/embulk-parser-xml.gemspec +1 -1
- data/lib/embulk/parser/xml.rb +5 -2
- 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: ace02cec80163c6715578043b31500af1783e4bd
|
4
|
+
data.tar.gz: 8ebd59d04f9ac7ae966b1c5bfff085a4dae0f1fa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ed2ee84816accf96eb8b391f7bc11f2a771d545a1f48ebb994a25ff7c0ed9042ccc0030caaa4a1a567b5688c0f79c12665971c8d063205e6d1b1683663fef0ff
|
7
|
+
data.tar.gz: fa8dfb6de0f1953f2eaffb3c1003081c3095d8dc27d9097c500327dadb46c4460ad99700703ea8f70f5ce3b76c443034e8d785ffb03be389fafc064921eb3211
|
data/embulk-parser-xml.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-xml"
|
7
|
-
spec.version = "0.0.
|
7
|
+
spec.version = "0.0.4"
|
8
8
|
spec.authors = ["Takuma kanari"]
|
9
9
|
spec.email = ["chemtrails.t@gmail.com"]
|
10
10
|
spec.summary = %q{Embulk parser plugin for XML}
|
data/lib/embulk/parser/xml.rb
CHANGED
@@ -30,8 +30,11 @@ module Embulk
|
|
30
30
|
@task["schema"], on_new_record)
|
31
31
|
parser = Nokogiri::XML::SAX::Parser.new(doc)
|
32
32
|
while file = file_input.next_file
|
33
|
-
|
34
|
-
|
33
|
+
data = file.read
|
34
|
+
if !data.nil? && !data.empty?
|
35
|
+
doc.clear
|
36
|
+
parser.parse(data)
|
37
|
+
end
|
35
38
|
end
|
36
39
|
@page_builder.finish
|
37
40
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: embulk-parser-xml
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Takuma kanari
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-08-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: nokogiri
|
@@ -86,7 +86,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
86
86
|
version: '0'
|
87
87
|
requirements: []
|
88
88
|
rubyforge_project:
|
89
|
-
rubygems_version: 2.
|
89
|
+
rubygems_version: 2.2.2
|
90
90
|
signing_key:
|
91
91
|
specification_version: 4
|
92
92
|
summary: Embulk parser plugin for XML
|