pxindex-builder 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 104ca6fc743176ff16ad3a8c04708b0e12cfbdb1
4
- data.tar.gz: c726681463709bf8732cc192f7177c1500e89f8c
3
+ metadata.gz: 67934e9d607e3570a66cf15e057f400ff5ecf589
4
+ data.tar.gz: fd66201c28faf4f5227ec224c81eb00ef8751a5a
5
5
  SHA512:
6
- metadata.gz: 260251027050a9c28eb84f634b7412da6400220ffd4ba870e4d0b5c5e09d9619d0eb393908b4c040929634a0db1bb8e7a4515f7487a0954cac83086167c424ba
7
- data.tar.gz: e35eb7185354cf457899a5e67fe790ed8fd63e4c2f3a6aa30a91747ff77858ca7b4e4cba8a2a46b24f2b56c3e48f282b3448278da3436ed9f48ce3e3c443935b
6
+ metadata.gz: 40f97d7d4c6a4201f63bacbaefa3374f92887285064b152f25f8d6a1f0efac63e63d390908215984ab0cc6976e24074c0daaaaa5e4eabdc26e2033cea65a42b8
7
+ data.tar.gz: 00c5a55685c184d0af6b9dcdbc6423e38d3120f96a4b7e48ac5014a7d3303ee02fba27512e62033343937d75f3a36569a9602e227c97f8a56f545f9ae57bbeac
checksums.yaml.gz.sig CHANGED
Binary file
@@ -11,11 +11,16 @@ class PxIndexBuilder
11
11
 
12
12
  attr_reader :to_xml, :to_h
13
13
 
14
- def initialize(raw_s, ignore=[])
14
+ def initialize(obj, ignore=[])
15
15
 
16
- s, _ = RXFHelper.read(raw_s)
17
-
18
- h = YAML.load(s)
16
+ h = if obj.is_a? String then
17
+
18
+ s, _ = RXFHelper.read(obj)
19
+ YAML.load(s)
20
+
21
+ elsif obj.is_a? Hash
22
+ obj
23
+ end
19
24
 
20
25
  words = h.keys.join(' ').split(/ +/).map {|x| x[/\w+/]}.uniq\
21
26
  #.tap {|x| puts 't: ' + x.inspect}
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pxindex-builder
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Robertson
@@ -31,7 +31,7 @@ cert_chain:
31
31
  rpKyBm8O20gPepUR+u4B3OOMZL1vUMzoAppGGdK/fa9iZHfP9tccqmgXIQ8c4X1f
32
32
  C74enOZQySX7LA==
33
33
  -----END CERTIFICATE-----
34
- date: 2017-10-22 00:00:00.000000000 Z
34
+ date: 2017-12-17 00:00:00.000000000 Z
35
35
  dependencies:
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: wordsdotdat
@@ -62,7 +62,7 @@ dependencies:
62
62
  version: '0.1'
63
63
  - - ">="
64
64
  - !ruby/object:Gem::Version
65
- version: 0.1.3
65
+ version: 0.1.5
66
66
  type: :runtime
67
67
  prerelease: false
68
68
  version_requirements: !ruby/object:Gem::Requirement
@@ -72,7 +72,7 @@ dependencies:
72
72
  version: '0.1'
73
73
  - - ">="
74
74
  - !ruby/object:Gem::Version
75
- version: 0.1.3
75
+ version: 0.1.5
76
76
  - !ruby/object:Gem::Dependency
77
77
  name: polyrex-builder
78
78
  requirement: !ruby/object:Gem::Requirement
metadata.gz.sig CHANGED
Binary file