relaton-iso 1.15.1 → 1.15.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/rake.yml +1 -0
- data/.github/workflows/release.yml +3 -2
- data/.rubocop.yml +1 -1
- data/Gemfile +9 -0
- data/lib/relaton_iso/scrapper.rb +15 -2
- data/lib/relaton_iso/version.rb +1 -1
- data/relaton_iso.gemspec +2 -10
- metadata +11 -123
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e27efa3183e068be1eb194fb2370fb91323c43435a6bfa28a3984fc5ee8f087d
|
4
|
+
data.tar.gz: a571f80e6fab8d18ead5b7f54666e16624a11b6c89637f3b7936a316ae25ee33
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9225503e6deb080fc61d003df621e46ec5ba2435dd9c201f2771345c468d269a45f89690cb77bda27c8a70e2211d695d53942d3ac192c3b48ae0e9ffabad86ec
|
7
|
+
data.tar.gz: 6cc63106785022a14c4bb48f9e2263df8d6e25716af94905e1b91a79ebea9a3014cdcdf4f2ae1d3172ba3ab34b22c1583bc2f7e84bc95308041e81bbfa3a95c6
|
data/.github/workflows/rake.yml
CHANGED
data/.rubocop.yml
CHANGED
data/Gemfile
CHANGED
@@ -4,3 +4,12 @@ git_source(:github) { |repo_name| "https://github.com/#{repo_name}" }
|
|
4
4
|
|
5
5
|
# Specify your gem's dependencies in relaton_iso.gemspec
|
6
6
|
gemspec
|
7
|
+
|
8
|
+
gem "byebug"
|
9
|
+
gem "pry-byebug"
|
10
|
+
gem "rubocop"
|
11
|
+
gem "rubocop-performance"
|
12
|
+
gem "rubocop-rails"
|
13
|
+
gem "simplecov"
|
14
|
+
gem "vcr"
|
15
|
+
gem "webmock"
|
data/lib/relaton_iso/scrapper.rb
CHANGED
@@ -93,8 +93,8 @@ module RelatonIso
|
|
93
93
|
#
|
94
94
|
# Create document ids.
|
95
95
|
#
|
96
|
-
# @param doc [Nokogiri::HTML::Document] document
|
97
|
-
# @param pubid [Pubid::Iso::Identifier]
|
96
|
+
# @param doc [Nokogiri::HTML::Document] document to parse
|
97
|
+
# @param pubid [Pubid::Iso::Identifier] publication identifier
|
98
98
|
#
|
99
99
|
# @return [Array<RelatonBib::DocumentIdentifier>]
|
100
100
|
#
|
@@ -102,10 +102,23 @@ module RelatonIso
|
|
102
102
|
pubid.stage ||= Pubid::Iso::Identifier.parse_stage(stage_code(doc))
|
103
103
|
[
|
104
104
|
RelatonIso::DocumentIdentifier.new(id: pubid, type: "ISO", primary: true),
|
105
|
+
RelatonBib::DocumentIdentifier.new(id: isoref(pubid), type: "iso-reference"),
|
105
106
|
RelatonIso::DocumentIdentifier.new(id: pubid, type: "URN"),
|
106
107
|
]
|
107
108
|
end
|
108
109
|
|
110
|
+
#
|
111
|
+
# Create ISO reference identifier with English language.
|
112
|
+
#
|
113
|
+
# @param [Pubid::Iso::Identifier] pubid publication identifier
|
114
|
+
#
|
115
|
+
# @return [String] English reference identifier
|
116
|
+
#
|
117
|
+
def isoref(pubid)
|
118
|
+
params = pubid.get_params.reject { |k, _| k == :typed_stage }
|
119
|
+
Pubid::Iso::Identifier.create(language: "en", **params).to_s(format: :ref_num_short)
|
120
|
+
end
|
121
|
+
|
109
122
|
private
|
110
123
|
|
111
124
|
# Fetch titles and abstracts.
|
data/lib/relaton_iso/version.rb
CHANGED
data/relaton_iso.gemspec
CHANGED
@@ -24,21 +24,13 @@ Gem::Specification.new do |spec|
|
|
24
24
|
spec.bindir = "exe"
|
25
25
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
26
26
|
spec.require_paths = ["lib"]
|
27
|
-
spec.required_ruby_version = Gem::Requirement.new(">= 2.
|
27
|
+
spec.required_ruby_version = Gem::Requirement.new(">= 2.7.0")
|
28
28
|
|
29
|
-
spec.add_development_dependency "byebug"
|
30
29
|
spec.add_development_dependency "equivalent-xml", "~> 0.6"
|
31
|
-
spec.add_development_dependency "pry-byebug"
|
32
30
|
spec.add_development_dependency "rake", "~> 13.0"
|
33
31
|
spec.add_development_dependency "rspec", "~> 3.0"
|
34
|
-
spec.add_development_dependency "rubocop"
|
35
|
-
spec.add_development_dependency "rubocop-performance"
|
36
|
-
spec.add_development_dependency "rubocop-rails"
|
37
|
-
spec.add_development_dependency "simplecov"
|
38
|
-
spec.add_development_dependency "vcr"
|
39
|
-
spec.add_development_dependency "webmock"
|
40
32
|
|
41
|
-
spec.add_dependency "algolia"
|
33
|
+
spec.add_dependency "algolia", "~> 2.3.0"
|
42
34
|
spec.add_dependency "pubid-iso", "~> 0.5.0"
|
43
35
|
spec.add_dependency "relaton-iso-bib", "~> 1.14.0"
|
44
36
|
end
|
metadata
CHANGED
@@ -1,29 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: relaton-iso
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.15.
|
4
|
+
version: 1.15.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-05-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
|
-
- !ruby/object:Gem::Dependency
|
14
|
-
name: byebug
|
15
|
-
requirement: !ruby/object:Gem::Requirement
|
16
|
-
requirements:
|
17
|
-
- - ">="
|
18
|
-
- !ruby/object:Gem::Version
|
19
|
-
version: '0'
|
20
|
-
type: :development
|
21
|
-
prerelease: false
|
22
|
-
version_requirements: !ruby/object:Gem::Requirement
|
23
|
-
requirements:
|
24
|
-
- - ">="
|
25
|
-
- !ruby/object:Gem::Version
|
26
|
-
version: '0'
|
27
13
|
- !ruby/object:Gem::Dependency
|
28
14
|
name: equivalent-xml
|
29
15
|
requirement: !ruby/object:Gem::Requirement
|
@@ -38,20 +24,6 @@ dependencies:
|
|
38
24
|
- - "~>"
|
39
25
|
- !ruby/object:Gem::Version
|
40
26
|
version: '0.6'
|
41
|
-
- !ruby/object:Gem::Dependency
|
42
|
-
name: pry-byebug
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
- - ">="
|
46
|
-
- !ruby/object:Gem::Version
|
47
|
-
version: '0'
|
48
|
-
type: :development
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
51
|
-
requirements:
|
52
|
-
- - ">="
|
53
|
-
- !ruby/object:Gem::Version
|
54
|
-
version: '0'
|
55
27
|
- !ruby/object:Gem::Dependency
|
56
28
|
name: rake
|
57
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -80,104 +52,20 @@ dependencies:
|
|
80
52
|
- - "~>"
|
81
53
|
- !ruby/object:Gem::Version
|
82
54
|
version: '3.0'
|
83
|
-
- !ruby/object:Gem::Dependency
|
84
|
-
name: rubocop
|
85
|
-
requirement: !ruby/object:Gem::Requirement
|
86
|
-
requirements:
|
87
|
-
- - ">="
|
88
|
-
- !ruby/object:Gem::Version
|
89
|
-
version: '0'
|
90
|
-
type: :development
|
91
|
-
prerelease: false
|
92
|
-
version_requirements: !ruby/object:Gem::Requirement
|
93
|
-
requirements:
|
94
|
-
- - ">="
|
95
|
-
- !ruby/object:Gem::Version
|
96
|
-
version: '0'
|
97
|
-
- !ruby/object:Gem::Dependency
|
98
|
-
name: rubocop-performance
|
99
|
-
requirement: !ruby/object:Gem::Requirement
|
100
|
-
requirements:
|
101
|
-
- - ">="
|
102
|
-
- !ruby/object:Gem::Version
|
103
|
-
version: '0'
|
104
|
-
type: :development
|
105
|
-
prerelease: false
|
106
|
-
version_requirements: !ruby/object:Gem::Requirement
|
107
|
-
requirements:
|
108
|
-
- - ">="
|
109
|
-
- !ruby/object:Gem::Version
|
110
|
-
version: '0'
|
111
|
-
- !ruby/object:Gem::Dependency
|
112
|
-
name: rubocop-rails
|
113
|
-
requirement: !ruby/object:Gem::Requirement
|
114
|
-
requirements:
|
115
|
-
- - ">="
|
116
|
-
- !ruby/object:Gem::Version
|
117
|
-
version: '0'
|
118
|
-
type: :development
|
119
|
-
prerelease: false
|
120
|
-
version_requirements: !ruby/object:Gem::Requirement
|
121
|
-
requirements:
|
122
|
-
- - ">="
|
123
|
-
- !ruby/object:Gem::Version
|
124
|
-
version: '0'
|
125
|
-
- !ruby/object:Gem::Dependency
|
126
|
-
name: simplecov
|
127
|
-
requirement: !ruby/object:Gem::Requirement
|
128
|
-
requirements:
|
129
|
-
- - ">="
|
130
|
-
- !ruby/object:Gem::Version
|
131
|
-
version: '0'
|
132
|
-
type: :development
|
133
|
-
prerelease: false
|
134
|
-
version_requirements: !ruby/object:Gem::Requirement
|
135
|
-
requirements:
|
136
|
-
- - ">="
|
137
|
-
- !ruby/object:Gem::Version
|
138
|
-
version: '0'
|
139
|
-
- !ruby/object:Gem::Dependency
|
140
|
-
name: vcr
|
141
|
-
requirement: !ruby/object:Gem::Requirement
|
142
|
-
requirements:
|
143
|
-
- - ">="
|
144
|
-
- !ruby/object:Gem::Version
|
145
|
-
version: '0'
|
146
|
-
type: :development
|
147
|
-
prerelease: false
|
148
|
-
version_requirements: !ruby/object:Gem::Requirement
|
149
|
-
requirements:
|
150
|
-
- - ">="
|
151
|
-
- !ruby/object:Gem::Version
|
152
|
-
version: '0'
|
153
|
-
- !ruby/object:Gem::Dependency
|
154
|
-
name: webmock
|
155
|
-
requirement: !ruby/object:Gem::Requirement
|
156
|
-
requirements:
|
157
|
-
- - ">="
|
158
|
-
- !ruby/object:Gem::Version
|
159
|
-
version: '0'
|
160
|
-
type: :development
|
161
|
-
prerelease: false
|
162
|
-
version_requirements: !ruby/object:Gem::Requirement
|
163
|
-
requirements:
|
164
|
-
- - ">="
|
165
|
-
- !ruby/object:Gem::Version
|
166
|
-
version: '0'
|
167
55
|
- !ruby/object:Gem::Dependency
|
168
56
|
name: algolia
|
169
57
|
requirement: !ruby/object:Gem::Requirement
|
170
58
|
requirements:
|
171
|
-
- - "
|
59
|
+
- - "~>"
|
172
60
|
- !ruby/object:Gem::Version
|
173
|
-
version:
|
61
|
+
version: 2.3.0
|
174
62
|
type: :runtime
|
175
63
|
prerelease: false
|
176
64
|
version_requirements: !ruby/object:Gem::Requirement
|
177
65
|
requirements:
|
178
|
-
- - "
|
66
|
+
- - "~>"
|
179
67
|
- !ruby/object:Gem::Version
|
180
|
-
version:
|
68
|
+
version: 2.3.0
|
181
69
|
- !ruby/object:Gem::Dependency
|
182
70
|
name: pubid-iso
|
183
71
|
requirement: !ruby/object:Gem::Requirement
|
@@ -259,7 +147,7 @@ homepage: https://github.com/relaton/relaton-iso
|
|
259
147
|
licenses:
|
260
148
|
- BSD-2-Clause
|
261
149
|
metadata: {}
|
262
|
-
post_install_message:
|
150
|
+
post_install_message:
|
263
151
|
rdoc_options: []
|
264
152
|
require_paths:
|
265
153
|
- lib
|
@@ -267,15 +155,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
267
155
|
requirements:
|
268
156
|
- - ">="
|
269
157
|
- !ruby/object:Gem::Version
|
270
|
-
version: 2.
|
158
|
+
version: 2.7.0
|
271
159
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
272
160
|
requirements:
|
273
161
|
- - ">="
|
274
162
|
- !ruby/object:Gem::Version
|
275
163
|
version: '0'
|
276
164
|
requirements: []
|
277
|
-
rubygems_version: 3.
|
278
|
-
signing_key:
|
165
|
+
rubygems_version: 3.4.9
|
166
|
+
signing_key:
|
279
167
|
specification_version: 4
|
280
168
|
summary: 'RelatonIso: retrieve ISO Standards for bibliographic use using the IsoBibliographicItem
|
281
169
|
model'
|