omniauth-linear 1.0.2 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b15af26154ea53db658069088d2631ffe11ce70e68828cb8c38190974dc6b3ce
4
- data.tar.gz: 2a1fcc493714b189949b7b3ac9583cdcd7e6e3de086e58b689b8b87dca58b5ea
3
+ metadata.gz: c61945254e398bf9d116163f5ebd1cf8a7c473ca391ca29586f745c6504f2d53
4
+ data.tar.gz: 3e1c2d029fbc87e3aef9560d40977fe06affb82a3b174c954899bc8a303d9cf7
5
5
  SHA512:
6
- metadata.gz: abe2526f15c5723eeeb2ea89b8c81d18e3e4d461e36e51af77380656ea1bc4a780379d05ce343033a82db7b214d6fe39c8fbed68de0106809264584f7686dc5c
7
- data.tar.gz: b7850dc202621e39f5d09029b6d953af1e6fbc07cae15a144bac90fc9b96369999181643532688f3caa91ac8ce35ea15c54ab9efcf5d008b166f5391e1488ccd
6
+ metadata.gz: e16a007e9e9202ebe5ca3d40e6468b15e3c7ee86153488226b01ae906c4f0b2a8bd493822a72cd981d0bb05ea1cfa9889c4eaea176b8a38489891f359295ef36
7
+ data.tar.gz: 318d7760ee360663d5bd91e6504c48e155af99c4dc329d0905511434d5f7478f6fafc7d68fa713efdad26c4e042ca4d5340d75c2eb91ee925e152803bd47da24
@@ -7,12 +7,12 @@ jobs:
7
7
  runs-on: ubuntu-latest
8
8
  strategy:
9
9
  matrix:
10
- ruby-version: ["2.4", "2.5", "2.6", "2.7"]
10
+ ruby-version: ["3.0", "3.1", "3.2", "3.3"]
11
11
 
12
12
  steps:
13
- - uses: actions/checkout@v2
13
+ - uses: actions/checkout@v3
14
14
  - name: Set up Ruby ${{ matrix.ruby-version }}
15
- uses: actions/setup-ruby@v1
15
+ uses: ruby/setup-ruby@v1
16
16
  with:
17
17
  ruby-version: ${{ matrix.ruby-version }}
18
18
  - name: Build and test with Rake
data/.gitignore CHANGED
@@ -15,3 +15,5 @@ spec/reports
15
15
  test/tmp
16
16
  test/version_tmp
17
17
  tmp
18
+
19
+ .ruby-version
@@ -30,10 +30,10 @@ module OmniAuth
30
30
  end
31
31
  end
32
32
 
33
- uid { me.viewer.id }
33
+ uid { "#{me['organization']['id']}-#{me['viewer']['id']}" }
34
34
 
35
35
  extra do
36
- { raw_info: raw_info, me: me.viewer }
36
+ { raw_info: raw_info, me: me['viewer'], organization: me['organization'] }
37
37
  end
38
38
 
39
39
  def raw_info
@@ -53,6 +53,10 @@ module OmniAuth
53
53
 
54
54
  gql = client.parse <<~GRAPHQL
55
55
  query {
56
+ organization {
57
+ id
58
+ name
59
+ }
56
60
  viewer {
57
61
  id
58
62
  name
@@ -61,15 +65,15 @@ module OmniAuth
61
65
  }
62
66
  GRAPHQL
63
67
  response = client.query(gql, context: {token: access_token.token})
64
- response.data
68
+ response.data.to_h
65
69
  end
66
70
  end
67
71
 
68
72
  def callback_url
69
- full_host + script_name + callback_path
73
+ "#{full_host}#{callback_path}"
70
74
  end
71
75
  end
72
76
  end
73
77
  end
74
78
 
75
- OmniAuth.config.add_camelization 'linear', 'Linear'
79
+ OmniAuth.config.add_camelization 'linear', 'Linear'
@@ -1,5 +1,5 @@
1
1
  module OmniAuth
2
2
  module Linear
3
- VERSION = "1.0.2"
3
+ VERSION = "2.0.0"
4
4
  end
5
5
  end
@@ -16,7 +16,9 @@ Gem::Specification.new do |gem|
16
16
  gem.require_paths = ["lib"]
17
17
  gem.version = OmniAuth::Linear::VERSION
18
18
 
19
- gem.add_dependency 'omniauth', '~> 1.5'
19
+ gem.required_ruby_version = ">= 3"
20
+
21
+ gem.add_dependency 'omniauth', '~> 2.0.0'
20
22
  gem.add_dependency 'omniauth-oauth2', '>= 1.4.0', '< 2.0'
21
23
  gem.add_dependency 'graphql-client'
22
24
  gem.add_development_dependency 'rspec', '~> 3.5'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: omniauth-linear
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.2
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Quentin Rousseau
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-10-01 00:00:00.000000000 Z
11
+ date: 2024-01-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: omniauth
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '1.5'
19
+ version: 2.0.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '1.5'
26
+ version: 2.0.0
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: omniauth-oauth2
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -139,7 +139,7 @@ homepage: https://github.com/kwent/omniauth-linear
139
139
  licenses:
140
140
  - MIT
141
141
  metadata: {}
142
- post_install_message:
142
+ post_install_message:
143
143
  rdoc_options: []
144
144
  require_paths:
145
145
  - lib
@@ -147,15 +147,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
147
147
  requirements:
148
148
  - - ">="
149
149
  - !ruby/object:Gem::Version
150
- version: '0'
150
+ version: '3'
151
151
  required_rubygems_version: !ruby/object:Gem::Requirement
152
152
  requirements:
153
153
  - - ">="
154
154
  - !ruby/object:Gem::Version
155
155
  version: '0'
156
156
  requirements: []
157
- rubygems_version: 3.0.3.1
158
- signing_key:
157
+ rubygems_version: 3.3.26
158
+ signing_key:
159
159
  specification_version: 4
160
160
  summary: Official OmniAuth strategy for Linear.
161
161
  test_files: