access_token_agent 3.5.0 → 4.0.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9ce5b9bb39e762a8602e908ed0fd3f90a5a90a1ab5692b37512fd51fca5ffcbc
4
- data.tar.gz: eb3bec64d9424a5197fc19e93ae26dd0d59f29a33fe3f1141dbffeed5e28ac9d
3
+ metadata.gz: 18af8e541c53b820506f84156a99fb17be090ab614f76c435f4129e89ac7c4d8
4
+ data.tar.gz: 2768ea522b78cb1735fba2caedead636c7ff0e2f504bb67a5101f7c1390bb072
5
5
  SHA512:
6
- metadata.gz: e6d2d273fb9013401936d16db02677ca8f84e843fe1634d79a2e03edab29eac96ee395d73275640177d610974bf652c1fe44303484d6150c22596db914118ee5
7
- data.tar.gz: 1395a40b82a22e93cd3ff04b7b61fb56d5c76a281dc567f5713a5e3cdbec6558d545c506668f51ee7a374b277576b6bd8b931b0ecf64c6b470d5381f82250304
6
+ metadata.gz: 15ad3cf054ccbc0057469518aeb173a19a6f001689767476eb4c992d3f380bb9b80cb60add5909932dfecac9508f500f593b11879cc6d0eb54b529a611b0590e
7
+ data.tar.gz: 458f7aec7acbacdc824c5200b38833e89a3c5cdb4b83b5fe4514ec9a6f446cd9370df17b503578af39449eae04fec2186b298c47b5d2ad7214d884594c970e3e
data/.gitlab-ci.yml CHANGED
@@ -1,34 +1,34 @@
1
- image: ruby:2.7
1
+ image: public.ecr.aws/docker/library/ruby
2
2
 
3
3
  stages:
4
4
  - test
5
5
  - publish
6
6
 
7
7
  before_script:
8
- - bundle config jobs 8
9
- - bundle install --path=/tmp/bundler --quiet
8
+ - "echo ':ssl_verify_mode: 0' >> ~/.gemrc"
9
+ - bundle config ssl_verify_mode 0
10
+ - bundle install --path=/tmp/bundler --jobs=8 --quiet
10
11
 
11
12
  rubocop:
12
13
  stage: test
13
- image: ruby:2.2
14
+ image: public.ecr.aws/docker/library/ruby:2.7
14
15
  script:
15
16
  - bundle exec rubocop
16
17
 
17
18
  rspec_latest:
18
19
  stage: test
19
- image: ruby
20
20
  script:
21
21
  - bundle exec rspec
22
22
 
23
23
  rspec_2.6:
24
24
  stage: test
25
- image: ruby:2.6
25
+ image: public.ecr.aws/docker/library/ruby:2.6
26
26
  script:
27
27
  - bundle exec rspec
28
28
 
29
29
  rspec_2.5:
30
30
  stage: test
31
- image: ruby:2.5
31
+ image: public.ecr.aws/docker/library/ruby:2.5
32
32
  script:
33
33
  - bundle exec rspec
34
34
 
@@ -41,14 +41,7 @@ rspec_2.2:
41
41
  publish_gem:
42
42
  stage: publish
43
43
  script:
44
- - mkdir -p ~/.gem
45
- - |
46
- cat << EOF > ~/.gem/credentials
47
- ---
48
- :rubygems_api_key: ${RUBYGEMS_API_KEY}
49
- EOF
50
- - chmod 0600 ~/.gem/credentials
51
44
  - gem build access_token_agent.gemspec
52
45
  - gem push $(find `pwd` -name "access_token_agent-*.gem")
53
46
  only:
54
- - master
47
+ - main
data/CHANGELOG.md CHANGED
@@ -1,3 +1,15 @@
1
+ ## 4.0.0 (2024-07-25)
2
+
3
+ - BREAKING: Remove deprecated `authenticate` method, use `token` instead
4
+
5
+ ## 3.5.2 (2024-06-12) yanked
6
+
7
+ - Use the new default branch (`main`, replacing `master`) in the publish job.
8
+
9
+ ## 3.5.1 (2023-05-24) yanked
10
+
11
+ - Publish gem to the new gem server
12
+
1
13
  ## 3.5.0
2
14
 
3
15
  - Support requesting scopes
data/Gemfile CHANGED
@@ -1,3 +1,4 @@
1
+ # frozen_string_literal: true
1
2
 
2
3
  source 'https://rubygems.org'
3
4
 
data/README.md CHANGED
@@ -63,21 +63,21 @@ AccessTokenAgent::Connector.instance = AccessTokenAgent::Connector.new(...)
63
63
  ## Usage
64
64
 
65
65
  Set up an AcccessTokenAgent::Connector instance (see Configuration) and call
66
- `authenticate` on it to receive your access_token.
66
+ `token` on it to receive your access_token.
67
67
 
68
68
  ```ruby
69
- AccessTokenAgent::Connector.instance.authenticate
69
+ AccessTokenAgent::Connector.instance.token
70
70
  => "XYZ"
71
71
  ```
72
72
 
73
- When no valid AccessToken is present a call to authenticate returns one of the
73
+ When no valid AccessToken is present a call to token returns one of the
74
74
  following:
75
75
  - a Bearer Token if the credentials are valid (auth response code 200)
76
76
  - raises an UnauthorizedError if the credentials are invalid (auth response
77
77
  code 401)
78
78
  - raises an Error if the auth response code is neither 200 nor 401
79
79
 
80
- As long as a valid AccessToken is present a call to authenticate simply returns
80
+ As long as a valid AccessToken is present a call to token simply returns
81
81
  that AccessToken. An AccessToken is valid for a limited time. The exact value is
82
82
  determined by the auth response which contains an `expires_at` parameter.
83
83
 
@@ -33,12 +33,6 @@ module AccessTokenAgent
33
33
  @known_token.value
34
34
  end
35
35
 
36
- def authenticate
37
- warn "[DEPRECATION] `#{self.class}.authenticate` is deprecated. " \
38
- 'Use `token` instead.'
39
- token
40
- end
41
-
42
36
  private
43
37
 
44
38
  def fetch_token
@@ -1,3 +1,3 @@
1
1
  module AccessTokenAgent
2
- VERSION = '3.5.0'.freeze
2
+ VERSION = '4.0.0'.freeze
3
3
  end
metadata CHANGED
@@ -1,11 +1,11 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: access_token_agent
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.5.0
4
+ version: 4.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - be Around GmbH
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
  date: 2020-10-02 00:00:00.000000000 Z
@@ -145,7 +145,7 @@ homepage: https://github.com/aroundhome/access_token_agent
145
145
  licenses:
146
146
  - MIT
147
147
  metadata: {}
148
- post_install_message:
148
+ post_install_message:
149
149
  rdoc_options: []
150
150
  require_paths:
151
151
  - lib
@@ -160,8 +160,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
160
160
  - !ruby/object:Gem::Version
161
161
  version: '0'
162
162
  requirements: []
163
- rubygems_version: 3.1.4
164
- signing_key:
163
+ rubygems_version: 3.5.11
164
+ signing_key:
165
165
  specification_version: 4
166
166
  summary: Handles authentication against an OAuth2 provider
167
167
  test_files: []