relaton-oasis 1.16.0 → 1.16.1
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
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6667e673a229cfd5518f00a5c6d021382effa374ad0dfaad7da60865829f6b40
|
4
|
+
data.tar.gz: 82b404a95e5f02139f6a79c601c1a13102d64d8b006d2ac1cf84c5c3c2cbc173
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7c0025fadba0c8c04c32b0b35e2212673bed7396953ae5b9164c8a88e958815e5cf932abe44d09d248a24d0f33876fb11c891a08559171d59da01db87ba34f68
|
7
|
+
data.tar.gz: e9c189383c69ed791232f05fd4a2fa52bf3f07040f67f7cc87cd8bb394352b1b891b88aeee9fb0ac7daa998f01c3ec96c679e12b623aba091f1baaf0e95a7a28
|
@@ -16,8 +16,9 @@ module RelatonOasis
|
|
16
16
|
@technology_area = args.delete(:technology_area) || []
|
17
17
|
uta = @technology_area.reject { |a| AREAS.include? a }
|
18
18
|
if uta.any?
|
19
|
-
|
20
|
-
warn "
|
19
|
+
area = uta.size > 1 ? "areas" : "area"
|
20
|
+
Util.warn "WARNING Unknown technology #{area}: `#{uta.join('`, `')}`"
|
21
|
+
Util.warn "Valid values are: `#{AREAS.join('`, `')}`"
|
21
22
|
end
|
22
23
|
super
|
23
24
|
end
|
@@ -34,15 +34,15 @@ module RelatonOasis
|
|
34
34
|
# reference is required
|
35
35
|
# @return [RelatonOasis::OasisBibliographicItem, nil]
|
36
36
|
def get(code, year = nil, _opts = {}) # rubocop:disable Metrics/CyclomaticComplexity,Metrics/MethodLength,Metrics/PerceivedComplexity
|
37
|
-
warn "
|
37
|
+
Util.warn "(#{code}) fetching..."
|
38
38
|
bibitem = search code, year
|
39
39
|
if bibitem
|
40
40
|
docid = bibitem.docidentifier.detect(&:primary).id
|
41
|
-
warn "
|
42
|
-
bibitem
|
41
|
+
Util.warn "(#{code}) found `#{docid}`"
|
43
42
|
else
|
44
|
-
warn "
|
43
|
+
Util.warn "(#{code}) not found"
|
45
44
|
end
|
45
|
+
bibitem
|
46
46
|
end
|
47
47
|
end
|
48
48
|
end
|
data/lib/relaton_oasis.rb
CHANGED
@@ -4,6 +4,8 @@ require "mechanize"
|
|
4
4
|
require "relaton/index"
|
5
5
|
require "relaton_bib"
|
6
6
|
require_relative "relaton_oasis/version"
|
7
|
+
require_relative "relaton_oasis/config"
|
8
|
+
require_relative "relaton_oasis/util"
|
7
9
|
require_relative "relaton_oasis/oasis_bibliographic_item"
|
8
10
|
require_relative "relaton_oasis/xml_parser"
|
9
11
|
require_relative "relaton_oasis/hash_converter"
|
@@ -21,9 +23,9 @@ module RelatonOasis
|
|
21
23
|
# Returns hash of XML reammar
|
22
24
|
# @return [String]
|
23
25
|
def self.grammar_hash
|
24
|
-
gem_path = File.expand_path "..", __dir__
|
25
|
-
grammars_path = File.join gem_path, "grammars", "*"
|
26
|
-
grammars = Dir[grammars_path].sort.map { |gp| File.read gp }.join
|
27
|
-
Digest::MD5.hexdigest grammars
|
26
|
+
# gem_path = File.expand_path "..", __dir__
|
27
|
+
# grammars_path = File.join gem_path, "grammars", "*"
|
28
|
+
# grammars = Dir[grammars_path].sort.map { |gp| File.read gp }.join
|
29
|
+
Digest::MD5.hexdigest RelatonOasis::VERSION + RelatonBib::VERSION # grammars
|
28
30
|
end
|
29
31
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: relaton-oasis
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.16.
|
4
|
+
version: 1.16.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-09-
|
11
|
+
date: 2023-09-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: mechanize
|
@@ -92,6 +92,7 @@ files:
|
|
92
92
|
- grammars/relaton-oasis-compile.rng
|
93
93
|
- grammars/relaton-oasis.rng
|
94
94
|
- lib/relaton_oasis.rb
|
95
|
+
- lib/relaton_oasis/config.rb
|
95
96
|
- lib/relaton_oasis/data_fetcher.rb
|
96
97
|
- lib/relaton_oasis/data_parser.rb
|
97
98
|
- lib/relaton_oasis/data_parser_utils.rb
|
@@ -101,6 +102,7 @@ files:
|
|
101
102
|
- lib/relaton_oasis/oasis_bibliographic_item.rb
|
102
103
|
- lib/relaton_oasis/oasis_bibliography.rb
|
103
104
|
- lib/relaton_oasis/processor.rb
|
105
|
+
- lib/relaton_oasis/util.rb
|
104
106
|
- lib/relaton_oasis/version.rb
|
105
107
|
- lib/relaton_oasis/xml_parser.rb
|
106
108
|
- relaton_oasis.gemspec
|