garage_client 2.4.4 → 2.4.6
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/.github/workflows/ci.yml +32 -0
- data/CHANGELOG.md +7 -0
- data/README.md +1 -1
- data/gemfiles/{Gemfile.faraday-0.8.x → Gemfile.faraday-0.x} +1 -1
- data/gemfiles/Gemfile.faraday-1.x +4 -0
- data/lib/garage_client/client.rb +2 -2
- data/lib/garage_client/version.rb +1 -1
- data/lib/garage_client.rb +8 -4
- metadata +9 -8
- data/.travis.yml +0 -16
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 897dd3b0bc65c1611c55f849ea5bfdc798cbfb252aa525f19c81aaadff2aadb0
|
4
|
+
data.tar.gz: 0a6def3201226a01ab1c415933ef3e4496ade096ab7e273a28694fe69cd657d2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c668202336fa97610663f9f5e321f114bc2b9254beba0feb2858828460bd7686ae250ff919740fd7b6108daaadc2f8277a6970c8e360e3bb134fde8528a9c115
|
7
|
+
data.tar.gz: dd21ae1aa64f9687a49a172e50b2b92e6af5f93b6dc68899b2a20d4d5c43d678dcb7f770bd65c952ba3d0eb10404c58aaf0950e9038ef9a91a6374afa66f619f
|
@@ -0,0 +1,32 @@
|
|
1
|
+
name: CI
|
2
|
+
|
3
|
+
on:
|
4
|
+
push:
|
5
|
+
pull_request:
|
6
|
+
|
7
|
+
jobs:
|
8
|
+
test:
|
9
|
+
runs-on: ubuntu-latest
|
10
|
+
strategy:
|
11
|
+
fail-fast: true
|
12
|
+
matrix:
|
13
|
+
ruby:
|
14
|
+
- '2.5'
|
15
|
+
- '2.6'
|
16
|
+
- '2.7'
|
17
|
+
- '3.0'
|
18
|
+
- 'head'
|
19
|
+
gemfile:
|
20
|
+
- 'gemfiles/Gemfile.faraday-0.x'
|
21
|
+
- 'gemfiles/Gemfile.faraday-1.x'
|
22
|
+
env:
|
23
|
+
BUNDLE_GEMFILE: ${{ matrix.gemfile }}
|
24
|
+
continue-on-error: ${{ endsWith(matrix.ruby, 'head') }}
|
25
|
+
name: Run test with Ruby ${{ matrix.ruby }}, ${{ matrix.gemfile }}
|
26
|
+
steps:
|
27
|
+
- uses: actions/checkout@v2
|
28
|
+
- uses: ruby/setup-ruby@v1
|
29
|
+
with:
|
30
|
+
ruby-version: ${{ matrix.ruby }}
|
31
|
+
bundler-cache: true
|
32
|
+
- run: bundle exec rspec
|
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
# GarageClient [](https://github.com/cookpad/garage_client/actions/workflows/ci.yml)
|
2
2
|
GarageClient is a simple Ruby library to provide a primitive client interface to the Garage application API.
|
3
3
|
|
4
4
|
## Install
|
data/lib/garage_client/client.rb
CHANGED
@@ -27,7 +27,7 @@ module GarageClient
|
|
27
27
|
end
|
28
28
|
|
29
29
|
def headers
|
30
|
-
@headers ||= GarageClient.configuration.headers.merge(given_headers.
|
30
|
+
@headers ||= GarageClient.configuration.headers.merge(given_headers.transform_keys(&:to_s))
|
31
31
|
end
|
32
32
|
alias :default_headers :headers
|
33
33
|
|
@@ -53,7 +53,7 @@ module GarageClient
|
|
53
53
|
end
|
54
54
|
|
55
55
|
def apply_auth_middleware(faraday_builder)
|
56
|
-
faraday_builder.authorization :Bearer, access_token if access_token
|
56
|
+
faraday_builder.request :authorization, :Bearer, access_token if access_token
|
57
57
|
end
|
58
58
|
|
59
59
|
def connection
|
data/lib/garage_client.rb
CHANGED
@@ -23,11 +23,15 @@ end
|
|
23
23
|
|
24
24
|
module GarageClient
|
25
25
|
class << self
|
26
|
-
GarageClient::Configuration.keys.each do |key|
|
27
|
-
|
28
|
-
|
26
|
+
[*GarageClient::Configuration.keys, :default_headers].each do |key|
|
27
|
+
define_method(key) do
|
28
|
+
configuration.public_send(key)
|
29
|
+
end
|
29
30
|
|
30
|
-
|
31
|
+
define_method("#{key}=") do |value|
|
32
|
+
configuration.public_send("#{key}=", value)
|
33
|
+
end
|
34
|
+
end
|
31
35
|
|
32
36
|
def configuration
|
33
37
|
@configuration ||= GarageClient::Configuration.new
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: garage_client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.4.
|
4
|
+
version: 2.4.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Cookpad Inc.
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2023-04-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -185,16 +185,17 @@ executables: []
|
|
185
185
|
extensions: []
|
186
186
|
extra_rdoc_files: []
|
187
187
|
files:
|
188
|
+
- ".github/workflows/ci.yml"
|
188
189
|
- ".gitignore"
|
189
190
|
- ".rspec"
|
190
|
-
- ".travis.yml"
|
191
191
|
- CHANGELOG.md
|
192
192
|
- Gemfile
|
193
193
|
- LICENSE.txt
|
194
194
|
- README.md
|
195
195
|
- Rakefile
|
196
196
|
- garage_client.gemspec
|
197
|
-
- gemfiles/Gemfile.faraday-0.
|
197
|
+
- gemfiles/Gemfile.faraday-0.x
|
198
|
+
- gemfiles/Gemfile.faraday-1.x
|
198
199
|
- lib/garage_client.rb
|
199
200
|
- lib/garage_client/cachers/base.rb
|
200
201
|
- lib/garage_client/client.rb
|
@@ -231,7 +232,7 @@ files:
|
|
231
232
|
homepage: https://github.com/cookpad/garage_client
|
232
233
|
licenses: []
|
233
234
|
metadata: {}
|
234
|
-
post_install_message:
|
235
|
+
post_install_message:
|
235
236
|
rdoc_options: []
|
236
237
|
require_paths:
|
237
238
|
- lib
|
@@ -246,8 +247,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
246
247
|
- !ruby/object:Gem::Version
|
247
248
|
version: '0'
|
248
249
|
requirements: []
|
249
|
-
rubygems_version: 3.
|
250
|
-
signing_key:
|
250
|
+
rubygems_version: 3.3.7
|
251
|
+
signing_key:
|
251
252
|
specification_version: 4
|
252
253
|
summary: Ruby client library for the Garage API
|
253
254
|
test_files:
|