relaton-bipm 1.16.2 → 1.16.3
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
- data/README.adoc +20 -28
- data/lib/relaton_bipm/bipm_bibliographic_item.rb +2 -2
- data/lib/relaton_bipm/bipm_bibliography.rb +3 -3
- data/lib/relaton_bipm/committee.rb +1 -1
- data/lib/relaton_bipm/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 3d8e6a865105cdcf8855183ef3e9a643f7b5927a45e7fb323933b35e6c785c5b
|
|
4
|
+
data.tar.gz: 7d0e021593a5b8e0da95ff90aaf7f62a769d2d96bff362779025b01cfc6f950a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 87020ee215e5bdd22faef4628a2dee2745e18a946da0fed498e374d1acc80bede9a4e3ea21afee2fd9375a0ef29ece739f5466cd45a32e73d991eead21272232
|
|
7
|
+
data.tar.gz: 0a009e46923cbfb67361f2edb48198a1a1f82022c4925fa3780bb5d6137ca3585fcf5de376aca5f743db11855db034a68acdc56b72f921351a9d2ebe7a4ce03c
|
data/README.adoc
CHANGED
|
@@ -33,14 +33,6 @@ Or install it yourself as:
|
|
|
33
33
|
|
|
34
34
|
=== Search for a standard using keywords
|
|
35
35
|
|
|
36
|
-
The Metrologia website employs anti-DDoS protection, which may cause the search to fail. If this happens, open provided link in a browser and solve the captcha.
|
|
37
|
-
|
|
38
|
-
----
|
|
39
|
-
[relaton-bipm] ("BIPM Metrologia 50 4 385") fetching...
|
|
40
|
-
[relaton-bipm] This source employs anti-DDoS measures that unfortunately affect automated requests.
|
|
41
|
-
[relaton-bipm] Please visit this link in your browser to resolve the CAPTCHA, then retry: https://iopscience.iop.org/article/10.1088/0026-1394/50/4/385
|
|
42
|
-
----
|
|
43
|
-
|
|
44
36
|
==== References for Si-Brochure documents
|
|
45
37
|
|
|
46
38
|
`BIPM {DOCUMENT_NAME}`
|
|
@@ -207,67 +199,67 @@ end
|
|
|
207
199
|
----
|
|
208
200
|
# get BIPM brochure
|
|
209
201
|
item = RelatonBipm::BipmBibliography.get "BIPM SI Brochure"
|
|
210
|
-
[relaton-bipm] (BIPM SI Brochure)
|
|
211
|
-
[relaton-bipm] (BIPM SI Brochure)
|
|
202
|
+
[relaton-bipm] (BIPM SI Brochure) Fetching from Relaton repository ...
|
|
203
|
+
[relaton-bipm] (BIPM SI Brochure) Found: `BIPM SI Brochure`
|
|
212
204
|
=> #<RelatonBipm::BipmBibliographicItem:0x007ffb83982fe8
|
|
213
205
|
...
|
|
214
206
|
|
|
215
207
|
# get BIPM Metrologia page
|
|
216
208
|
bib = RelatonBipm::BipmBibliography.get "BIPM Metrologia 29 6 001"
|
|
217
|
-
[relaton-bipm] (BIPM Metrologia 29 6 001)
|
|
218
|
-
[relaton-bipm] (BIPM Metrologia 29 6 001)
|
|
209
|
+
[relaton-bipm] (BIPM Metrologia 29 6 001) Fetching from Relaton repository ...
|
|
210
|
+
[relaton-bipm] (BIPM Metrologia 29 6 001) Found: `Metrologia 29 6 001`
|
|
219
211
|
=> #<RelatonBipm::BipmBibliographicItem:0x007f8857f94d40
|
|
220
212
|
...
|
|
221
213
|
|
|
222
214
|
# get CGPM meetings
|
|
223
215
|
RelatonBipm::BipmBibliography.get "CGPM 1st Meeting (1889)"
|
|
224
|
-
[relaton-bipm] (CGPM 1st Meeting (1889))
|
|
225
|
-
[relaton-bipm] (CGPM 1st Meeting (1889))
|
|
216
|
+
[relaton-bipm] (CGPM 1st Meeting (1889)) Fetching from Relaton repository ...
|
|
217
|
+
[relaton-bipm] (CGPM 1st Meeting (1889)) Found: `CGPM 1th meeting (1889)`
|
|
226
218
|
=> #<RelatonBipm::BipmBibliographicItem:0x00007f7fd02aba28
|
|
227
219
|
...
|
|
228
220
|
|
|
229
221
|
# get CGPM resolutions
|
|
230
222
|
RelatonBipm::BipmBibliography.get "CGPM RES (1889, E)"
|
|
231
|
-
[relaton-bipm] (CGPM RES (1889, E))
|
|
232
|
-
[relaton-bipm] (CGPM RES (1889, E))
|
|
223
|
+
[relaton-bipm] (CGPM RES (1889, E)) Fetching from Relaton repository ...
|
|
224
|
+
[relaton-bipm] (CGPM RES (1889, E)) Found: `CGPM RES (1889)`
|
|
233
225
|
=> #<RelatonBipm::BipmBibliographicItem:0x00007f80421f93d8
|
|
234
226
|
...
|
|
235
227
|
|
|
236
228
|
RelatonBipm::BipmBibliography.get "CGPM Resolution (1889)"
|
|
237
|
-
[relaton-bipm] (CGPM Resolution (1889))
|
|
238
|
-
[relaton-bipm] (CGPM Resolution (1889))
|
|
229
|
+
[relaton-bipm] (CGPM Resolution (1889)) Fetching from Relaton repository ...
|
|
230
|
+
[relaton-bipm] (CGPM Resolution (1889)) Found: `CGPM RES (1889)`
|
|
239
231
|
=> #<RelatonBipm::BipmBibliographicItem:0x00007f8017f60c18
|
|
240
232
|
...
|
|
241
233
|
|
|
242
234
|
RelatonBipm::BipmBibliography.get "CGPM Résolution (1889)"
|
|
243
|
-
[relaton-bipm] (CGPM Résolution (1889))
|
|
244
|
-
[relaton-bipm] (CGPM Résolution (1889))
|
|
235
|
+
[relaton-bipm] (CGPM Résolution (1889)) Fetching from Relaton repository ...
|
|
236
|
+
[relaton-bipm] (CGPM Résolution (1889)) Found: `CGPM RES (1889)`
|
|
245
237
|
=> #<RelatonBipm::BipmBibliographicItem:0x00007f8017f492e8
|
|
246
238
|
...
|
|
247
239
|
|
|
248
240
|
# get CIPM decision by year and decision number
|
|
249
241
|
RelatonBipm::BipmBibliography.get "BIPM Decision CIPM/101-1 (2012)"
|
|
250
|
-
[relaton-bipm] (BIPM Decision CIPM/101-1 (2012))
|
|
251
|
-
[relaton-bipm] (BIPM Decision CIPM/101-1 (2012))
|
|
242
|
+
[relaton-bipm] (BIPM Decision CIPM/101-1 (2012)) Fetching from Relaton repository ...
|
|
243
|
+
[relaton-bipm] (BIPM Decision CIPM/101-1 (2012)) Found: `CIPM DECN 101-1 (2012)`
|
|
252
244
|
=> #<RelatonBipm::BipmBibliographicItem:0x00007f8017f2bd88
|
|
253
245
|
...
|
|
254
246
|
|
|
255
247
|
RelatonBipm::BipmBibliography.get "BIPM DECN CIPM/101-1 (2012, E)"
|
|
256
|
-
[relaton-bipm] (BIPM DECN CIPM/101-1 (2012, E))
|
|
257
|
-
[relaton-bipm] (BIPM DECN CIPM/101-1 (2012, E))
|
|
248
|
+
[relaton-bipm] (BIPM DECN CIPM/101-1 (2012, E)) Fetching from Relaton repository ...
|
|
249
|
+
[relaton-bipm] (BIPM DECN CIPM/101-1 (2012, E)) Found: `CIPM DECN 101-1 (2012)`
|
|
258
250
|
=> #<RelatonBipm::BipmBibliographicItem:0x00007f8017f39438
|
|
259
251
|
...
|
|
260
252
|
|
|
261
253
|
# get CIPM recommendation
|
|
262
254
|
RelatonBipm::BipmBibliography.get "CIPM Recommendation 1 (2005)"
|
|
263
|
-
[relaton-bipm] (CIPM Recommendation 1 (2005))
|
|
264
|
-
[relaton-bipm] (CIPM Recommendation 1 (2005))
|
|
255
|
+
[relaton-bipm] (CIPM Recommendation 1 (2005)) Fetching from Relaton repository ...
|
|
256
|
+
[relaton-bipm] (CIPM Recommendation 1 (2005)) Found: `CIPM REC 1 (2005)`
|
|
265
257
|
=> #<RelatonBipm::BipmBibliographicItem:0x00007f8017f31da0
|
|
266
258
|
...
|
|
267
259
|
|
|
268
260
|
RelatonBipm::BipmBibliography.get "CIPM REC 1 (2005, FR)"
|
|
269
|
-
[relaton-bipm] (CIPM REC 1 (2005, FR))
|
|
270
|
-
[relaton-bipm] (CIPM REC 1 (2005, FR))
|
|
261
|
+
[relaton-bipm] (CIPM REC 1 (2005, FR)) Fetching from Relaton repository ...
|
|
262
|
+
[relaton-bipm] (CIPM REC 1 (2005, FR)) Found: `CIPM REC 1 (2005)`
|
|
271
263
|
=> #<RelatonBipm::BipmBibliographicItem:0x00007f80422100d8
|
|
272
264
|
...
|
|
273
265
|
----
|
|
@@ -27,12 +27,12 @@ module RelatonBipm
|
|
|
27
27
|
# @param structuredidentifier [RelatonBipm::StructuredIdentifier]
|
|
28
28
|
def initialize(**args) # rubocop:disable Metrics/AbcSize,Metrics/MethodLength
|
|
29
29
|
if args[:docstatus] && !STATUSES.include?(args[:docstatus].stage.value)
|
|
30
|
-
Util.warn "WARNING:
|
|
30
|
+
Util.warn "WARNING: Invalid docstatus: `#{args[:docstatus].stage.value}`. " \
|
|
31
31
|
"It should be one of: `#{STATUSES.join('`, `')}`"
|
|
32
32
|
end
|
|
33
33
|
|
|
34
34
|
if args[:si_aspect] && !SI_ASPECTS.include?(args[:si_aspect])
|
|
35
|
-
Util.warn "WARNING:
|
|
35
|
+
Util.warn "WARNING: Invalid si_aspect: `#{args[:si_aspect]}``. " \
|
|
36
36
|
"It should be one of: `#{SI_ASPECTS.join('`, `')}`"
|
|
37
37
|
end
|
|
38
38
|
|
|
@@ -9,15 +9,15 @@ module RelatonBipm
|
|
|
9
9
|
# @param text [String]
|
|
10
10
|
# @return [RelatonBipm::BipmBibliographicItem]
|
|
11
11
|
def search(text, _year = nil, _opts = {}) # rubocop:disable Metrics/AbcSize, Metrics/MethodLength
|
|
12
|
-
Util.warn "(#{text})
|
|
12
|
+
Util.warn "(#{text}) Fetching from Relaton repository ..."
|
|
13
13
|
ref = text.sub(/^BIPM\s/, "")
|
|
14
14
|
item = get_bipm ref
|
|
15
15
|
unless item
|
|
16
|
-
Util.warn "(#{text})
|
|
16
|
+
Util.warn "(#{text}) Not found."
|
|
17
17
|
return
|
|
18
18
|
end
|
|
19
19
|
|
|
20
|
-
Util.warn("(#{text})
|
|
20
|
+
Util.warn("(#{text}) Found: `#{item.docidentifier[0].id}`")
|
|
21
21
|
item
|
|
22
22
|
rescue Mechanize::ResponseCodeError => e
|
|
23
23
|
raise RelatonBib::RequestError, e.message unless e.response_code == "404"
|
|
@@ -11,7 +11,7 @@ module RelatonBipm
|
|
|
11
11
|
def initialize(acronym:, content: nil)
|
|
12
12
|
acronyms = YAML.load_file File.join(__dir__, "acronyms.yaml")
|
|
13
13
|
unless acronyms[acronym]
|
|
14
|
-
Util.warn "WARNING:
|
|
14
|
+
Util.warn "WARNING: Invalid acronym: `#{acronym}`. Allowed " \
|
|
15
15
|
"values: `#{acronyms.map { |k, _v| k }.join '`, `'}`"
|
|
16
16
|
end
|
|
17
17
|
|
data/lib/relaton_bipm/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: relaton-bipm
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.16.
|
|
4
|
+
version: 1.16.3
|
|
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-10-
|
|
11
|
+
date: 2023-10-07 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: faraday
|