kvx 0.9.6 → 0.9.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 +4 -4
- checksums.yaml.gz.sig +0 -0
- data.tar.gz.sig +0 -0
- data/lib/kvx.rb +11 -7
- metadata +3 -2
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: '03690b30a2cce31295d0d6eeffc8c142785ab25efb0bad30328a41121d0f1e28'
|
|
4
|
+
data.tar.gz: d16ee75eb0d6aec1641b9b1a544e459623195889860f579414f8b338151cdb08
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 0e5cfff4834e5f080f983608178807c0483db5073cb158cc64ccc1b95b05bd0dd2afe7d0e25dbcafb8648d08ea1b803c6f914e1907bc5f264a8c5510d05262b2
|
|
7
|
+
data.tar.gz: c8d3f742947f5dd4f10a54223ffb27b09c131d36ff443f2b2790120b16a570a9e253cf1677fd88f637158d0c3ee2f87d720530dd08655c17edb9f9854376cb05
|
checksums.yaml.gz.sig
CHANGED
|
Binary file
|
data.tar.gz.sig
CHANGED
|
Binary file
|
data/lib/kvx.rb
CHANGED
|
@@ -353,13 +353,14 @@ class Kvx
|
|
|
353
353
|
# if there are any orphan lines which aren't nested underneath a
|
|
354
354
|
# label, they will be fixed using the following statement
|
|
355
355
|
|
|
356
|
-
a = raw_a.chunk {|x| x[0][/^[^:]
|
|
356
|
+
a = raw_a.chunk {|x| x[0][/^[^:]+:/]}.inject([]) do |r,y|
|
|
357
357
|
|
|
358
358
|
puts 'r: ' + r.inspect if @debug
|
|
359
359
|
|
|
360
360
|
if r.last and !y.first[/[^:]+:/] then
|
|
361
361
|
r.last << y.last[-1]
|
|
362
362
|
else
|
|
363
|
+
puts 'y: ' + y.inspect if @debug
|
|
363
364
|
r << y.last[-1]
|
|
364
365
|
end
|
|
365
366
|
|
|
@@ -372,13 +373,16 @@ class Kvx
|
|
|
372
373
|
s = line.shift
|
|
373
374
|
puts ('s: ' + s.inspect).debug if @debug
|
|
374
375
|
|
|
375
|
-
if line.join.length > 0 then
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
376
|
+
if line.join.length > 0 then
|
|
377
|
+
|
|
378
|
+
puts 'line: ' + line.inspect if @debug
|
|
379
|
+
|
|
380
|
+
padding = line[0].length < 2 ? "\n" : "\n "
|
|
381
|
+
s10 = line.map{|x| x.join(padding)}.join("\n")
|
|
382
|
+
|
|
383
|
+
r2 = if s10[/^[^:]+:[\n ]/] then
|
|
380
384
|
|
|
381
|
-
scan_to_h(
|
|
385
|
+
scan_to_h(s10)
|
|
382
386
|
|
|
383
387
|
else
|
|
384
388
|
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: kvx
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.9.
|
|
4
|
+
version: 0.9.7
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- James Robertson
|
|
@@ -103,7 +103,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
103
103
|
- !ruby/object:Gem::Version
|
|
104
104
|
version: '0'
|
|
105
105
|
requirements: []
|
|
106
|
-
|
|
106
|
+
rubyforge_project:
|
|
107
|
+
rubygems_version: 2.7.10
|
|
107
108
|
signing_key:
|
|
108
109
|
specification_version: 4
|
|
109
110
|
summary: Kvx (Keys, Values, and XML) makes it convenient to store and retrieve the
|
metadata.gz.sig
CHANGED
|
Binary file
|