relaton-ogc 1.19.0 → 1.20.1
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/lib/relaton_ogc/hash_converter.rb +1 -1
- data/lib/relaton_ogc/scrapper.rb +17 -5
- data/lib/relaton_ogc/version.rb +1 -1
- data/relaton_ogc.gemspec +1 -1
- metadata +8 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2c5ff2e52f74939f5dd715e54318cc0f7beab1880965868c23b5e43514b62fd4
|
4
|
+
data.tar.gz: 5a190d493b779ae6d0e7fc1ff2e8529ed210901b5006d90db9470f6d26e87626
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: '069d2ea46db6d46a067f7949078b7bc1b670f1ab7de046e3ef862c3f17ba60a004a0d60f18266d05ca635f5a34954e415bfa1206e44d7a900d9720279e819580'
|
7
|
+
data.tar.gz: 74726f295ce90b5590f1fb79173d79aa4ff245fb60e39b61e1582bc2aaf50984e95ea58edcd0424dc09fcb5da7e84272a3c77256094b34778067eadce5077513
|
@@ -7,7 +7,7 @@ module RelatonOgc
|
|
7
7
|
|
8
8
|
# @param ret [Hash]
|
9
9
|
def editorialgroup_hash_to_bib(ret)
|
10
|
-
eg = ret[:editorialgroup]
|
10
|
+
eg = ret.dig(:ext, :editorialgroup) || ret[:editorialgroup] #@TODO: remove ret[:editorialgroup] after all gem will be updated
|
11
11
|
return unless eg
|
12
12
|
|
13
13
|
ret[:editorialgroup] = EditorialGroup.new(
|
data/lib/relaton_ogc/scrapper.rb
CHANGED
@@ -76,11 +76,23 @@ module RelatonOgc
|
|
76
76
|
# @return [Array>RelatonBib::TypedUri>]
|
77
77
|
def fetch_link(hit)
|
78
78
|
link = []
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
79
|
+
uri = hit["URI"].to_s.strip
|
80
|
+
link << RelatonBib::TypedUri.new(type: "src", content: uri) unless uri.empty?
|
81
|
+
return link unless hit["URL"] && !hit["URL"].strip.empty?
|
82
|
+
|
83
|
+
if ext = hit["URL"].match(/(?<=\.)(?<ext>pdf|html|doc)$/)
|
84
|
+
type = ext[:ext]
|
85
|
+
else
|
86
|
+
case hit["URL"]
|
87
|
+
when /portal\.(ogc|opengeospatial)\.org/, /usgif\.org/
|
88
|
+
type = "pdf"
|
89
|
+
when /www\.(w3|geopackage)\.org/, /docs\.ogc\.org/
|
90
|
+
type = "html"
|
91
|
+
else
|
92
|
+
type = "html"
|
93
|
+
end
|
94
|
+
end
|
95
|
+
link << RelatonBib::TypedUri.new(type: type, content: hit["URL"].strip)
|
84
96
|
end
|
85
97
|
|
86
98
|
def fetch_doctype(type)
|
data/lib/relaton_ogc/version.rb
CHANGED
data/relaton_ogc.gemspec
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: relaton-ogc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.20.1
|
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:
|
11
|
+
date: 2025-03-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -44,14 +44,14 @@ dependencies:
|
|
44
44
|
requirements:
|
45
45
|
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: 1.
|
47
|
+
version: 1.20.0
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: 1.
|
54
|
+
version: 1.20.0
|
55
55
|
description: 'RelatonOgc: retrieve OGC Standards for bibliographic use using the OgcBibliographicItem
|
56
56
|
model'
|
57
57
|
email:
|
@@ -97,7 +97,7 @@ homepage: https://github.com/relaton/relaton-ogc
|
|
97
97
|
licenses:
|
98
98
|
- BSD-2-Clause
|
99
99
|
metadata: {}
|
100
|
-
post_install_message:
|
100
|
+
post_install_message:
|
101
101
|
rdoc_options: []
|
102
102
|
require_paths:
|
103
103
|
- lib
|
@@ -112,8 +112,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
112
112
|
- !ruby/object:Gem::Version
|
113
113
|
version: '0'
|
114
114
|
requirements: []
|
115
|
-
rubygems_version: 3.
|
116
|
-
signing_key:
|
115
|
+
rubygems_version: 3.5.22
|
116
|
+
signing_key:
|
117
117
|
specification_version: 4
|
118
118
|
summary: 'RelatonOgc: retrieve OGC Standards for bibliographic use using the OgcBibliographicItem
|
119
119
|
model'
|