sdr-client 0.90.0 → 0.91.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +15 -15
- data/lib/sdr_client/deposit/update_resource.rb +9 -5
- data/lib/sdr_client/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: f8233c4bc5f385175264ff828603971ecf6f0e65e5ed5d973ce8eed2bf42be8e
|
4
|
+
data.tar.gz: 63cbe0407ada26d325730ad992a74964ae83cc3390a2a2ccd3b446b070c78969
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3b7fa91c363c8d88d53f168e17e9627cb773bdea6d51c2e3891e1ed5fdbcd57db731e9f021e7edc40b2426834e3d1c962627769126d605ba1f99134069dcdbb7
|
7
|
+
data.tar.gz: fbdbc1fafad4c9c1a47379fe697b8573b44cbd368b4a76ccdb7998898a93c3e9898286c8abf4b46326bd1c30ceed9ea1608fb3ba748e5cc44bb4415b8bb4581a
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
sdr-client (0.
|
4
|
+
sdr-client (0.91.0)
|
5
5
|
activesupport
|
6
6
|
cocina-models (~> 0.83.0)
|
7
7
|
dry-monads
|
@@ -43,9 +43,9 @@ GEM
|
|
43
43
|
activesupport
|
44
44
|
diff-lcs (1.5.0)
|
45
45
|
docile (1.4.0)
|
46
|
-
dry-container (0.10.
|
46
|
+
dry-container (0.10.1)
|
47
47
|
concurrent-ruby (~> 1.0)
|
48
|
-
dry-core (0.8.
|
48
|
+
dry-core (0.8.1)
|
49
49
|
concurrent-ruby (~> 1.0)
|
50
50
|
dry-inflector (0.3.0)
|
51
51
|
dry-logic (1.2.0)
|
@@ -68,10 +68,10 @@ GEM
|
|
68
68
|
activesupport (>= 3.0, < 8.0)
|
69
69
|
equivalent-xml (0.6.0)
|
70
70
|
nokogiri (>= 1.4.3)
|
71
|
-
faraday (2.
|
72
|
-
faraday-net_http (
|
71
|
+
faraday (2.5.2)
|
72
|
+
faraday-net_http (>= 2.0, < 3.1)
|
73
73
|
ruby2_keywords (>= 0.0.4)
|
74
|
-
faraday-net_http (
|
74
|
+
faraday-net_http (3.0.0)
|
75
75
|
hashdiff (1.0.1)
|
76
76
|
i18n (1.12.0)
|
77
77
|
concurrent-ruby (~> 1.0)
|
@@ -82,17 +82,17 @@ GEM
|
|
82
82
|
mini_portile2 (2.8.0)
|
83
83
|
minitest (5.16.2)
|
84
84
|
multi_json (1.15.0)
|
85
|
-
nokogiri (1.13.
|
85
|
+
nokogiri (1.13.8)
|
86
86
|
mini_portile2 (~> 2.8.0)
|
87
87
|
racc (~> 1.4)
|
88
|
-
nokogiri (1.13.
|
88
|
+
nokogiri (1.13.8-x86_64-darwin)
|
89
89
|
racc (~> 1.4)
|
90
90
|
openapi3_parser (0.9.2)
|
91
91
|
commonmarker (~> 0.17)
|
92
92
|
openapi_parser (0.15.0)
|
93
93
|
optimist (3.0.1)
|
94
94
|
parallel (1.22.1)
|
95
|
-
parser (3.1.2.
|
95
|
+
parser (3.1.2.1)
|
96
96
|
ast (~> 2.4.1)
|
97
97
|
patience_diff (1.2.0)
|
98
98
|
optimist (~> 3.0)
|
@@ -119,17 +119,17 @@ GEM
|
|
119
119
|
rspec-core (>= 2, < 4, != 2.12.0)
|
120
120
|
rss (0.2.9)
|
121
121
|
rexml
|
122
|
-
rubocop (1.
|
122
|
+
rubocop (1.35.0)
|
123
123
|
json (~> 2.3)
|
124
124
|
parallel (~> 1.10)
|
125
|
-
parser (>= 3.1.
|
125
|
+
parser (>= 3.1.2.1)
|
126
126
|
rainbow (>= 2.2.2, < 4.0)
|
127
127
|
regexp_parser (>= 1.8, < 3.0)
|
128
128
|
rexml (>= 3.2.5, < 4.0)
|
129
|
-
rubocop-ast (>= 1.
|
129
|
+
rubocop-ast (>= 1.20.1, < 2.0)
|
130
130
|
ruby-progressbar (~> 1.7)
|
131
131
|
unicode-display_width (>= 1.4.0, < 3.0)
|
132
|
-
rubocop-ast (1.
|
132
|
+
rubocop-ast (1.21.0)
|
133
133
|
parser (>= 3.1.1.0)
|
134
134
|
rubocop-rake (0.6.0)
|
135
135
|
rubocop (~> 1.0)
|
@@ -148,10 +148,10 @@ GEM
|
|
148
148
|
diff-lcs
|
149
149
|
patience_diff
|
150
150
|
thor (1.2.1)
|
151
|
-
tzinfo (2.0.
|
151
|
+
tzinfo (2.0.5)
|
152
152
|
concurrent-ruby (~> 1.0)
|
153
153
|
unicode-display_width (2.2.0)
|
154
|
-
webmock (3.
|
154
|
+
webmock (3.17.1)
|
155
155
|
addressable (>= 2.8.0)
|
156
156
|
crack (>= 0.3.2)
|
157
157
|
hashdiff (>= 0.4.0, < 2.0.0)
|
@@ -6,16 +6,18 @@ module SdrClient
|
|
6
6
|
class UpdateResource
|
7
7
|
DRO_PATH = '/v1/resources/%<id>s'
|
8
8
|
|
9
|
-
def self.run(metadata:, logger:, connection:)
|
10
|
-
new(metadata: metadata, logger: logger, connection: connection).run
|
9
|
+
def self.run(metadata:, logger:, connection:, version_description: nil)
|
10
|
+
new(metadata: metadata, logger: logger, connection: connection, version_description: version_description).run
|
11
11
|
end
|
12
12
|
|
13
13
|
# @param [Cocina::Models::DRO] metadata
|
14
14
|
# @param [Hash<Symbol,String>] the result of the metadata call
|
15
|
-
|
15
|
+
# @param [String] version_description
|
16
|
+
def initialize(metadata:, logger:, connection:, version_description: nil)
|
16
17
|
@metadata = metadata
|
17
18
|
@logger = logger
|
18
19
|
@connection = connection
|
20
|
+
@version_description = version_description
|
19
21
|
end
|
20
22
|
|
21
23
|
# @param [Hash<Symbol,String>] the result of the metadata call
|
@@ -31,7 +33,7 @@ module SdrClient
|
|
31
33
|
|
32
34
|
private
|
33
35
|
|
34
|
-
attr_reader :metadata, :logger, :connection
|
36
|
+
attr_reader :metadata, :logger, :connection, :version_description
|
35
37
|
|
36
38
|
def metadata_request
|
37
39
|
json = metadata.to_json
|
@@ -39,7 +41,9 @@ module SdrClient
|
|
39
41
|
|
40
42
|
connection.put(path(metadata), json,
|
41
43
|
'Content-Type' => 'application/json',
|
42
|
-
'X-Cocina-Models-Version' => Cocina::Models::VERSION)
|
44
|
+
'X-Cocina-Models-Version' => Cocina::Models::VERSION) do |req|
|
45
|
+
req.params['versionDescription'] = version_description if version_description
|
46
|
+
end
|
43
47
|
end
|
44
48
|
|
45
49
|
def path(metadata)
|
data/lib/sdr_client/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sdr-client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.91.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Justin Coyne
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-08-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|