fastlane-plugin-firebase_app_distribution 0.3.8 → 0.4.0.pre.2

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: 9054b14c72ce1d0b5ee23da37fc3da51a2860b3249b07e5271d281c47570e5d0
4
- data.tar.gz: 22e4f72109457476f1ab857e6dad86146ae3733972fda42cb80c8c73b89d42fc
3
+ metadata.gz: 55db8ec6da19d2aef3ff0b424a7be499ec58ba3a0d809e255718857ab96eb929
4
+ data.tar.gz: 8e57257d75b2a927b4053de36a860a8a5210a73265d6a562656066db3db4fbe6
5
5
  SHA512:
6
- metadata.gz: 80f3d004d4f6263a15c6aba591bb5ae10705dca4c9c31c8f6f0dc4f513e6fbe50310e605cae5b30a4c3bc28ac0eadca29d4bcd51b19b2ed3f970001df1b6d8fa
7
- data.tar.gz: 4f4b8f3780fd86299ea1c393e6446e02e5e4414b498b4f85b764a27f8584395f88b40325d54e33bd6e782bc9fe3b58960e8ba72fd5e6e453aba3d563e555e14b
6
+ metadata.gz: 76a7d4a98592086c59777bd7261129e7c6d666bcd05e43e7cbfa03ef9ae5a3ffc073223a9c62c2ae73b18fd4a4f76627e54dd964b04ca67e255ecc8cda70014d
7
+ data.tar.gz: fcc10c72a1b4cb937b34c0bafc5a703c3e5ccf694259cceefb73e1eaf454ee1089bdb291390cf247396a26d1908f6bcda85640366b5fde615428ac81abfbcd95
@@ -46,7 +46,8 @@ module Fastlane
46
46
 
47
47
  upload_timeout = get_upload_timeout(params)
48
48
 
49
- release_name = fad_api_client.upload(app_name, binary_path, platform.to_s, upload_timeout)
49
+ upload_status_response = fad_api_client.upload(app_name, binary_path, platform.to_s, upload_timeout)
50
+ release_name = upload_status_response.release_name
50
51
 
51
52
  if binary_type == :AAB && aab_info && !aab_info.certs_provided?
52
53
  updated_aab_info = fad_api_client.get_aab_info(app_name)
@@ -69,6 +70,18 @@ module Fastlane
69
70
  group_aliases = string_to_array(groups)
70
71
  fad_api_client.distribute(release_name, emails, group_aliases)
71
72
  UI.success("🎉 App Distribution upload finished successfully.")
73
+
74
+ if upload_status_response.firebase_console_uri
75
+ UI.message("🔗 View this release in the Firebase console: #{upload_status_response.firebase_console_uri}")
76
+ end
77
+
78
+ if upload_status_response.testing_uri
79
+ UI.message("🔗 Share this release with testers who have access: #{upload_status_response.testing_uri}")
80
+ end
81
+
82
+ if upload_status_response.binary_download_uri
83
+ UI.message("🔗 Download the release binary (link expires in 1 hour): #{upload_status_response.binary_download_uri}")
84
+ end
72
85
  end
73
86
 
74
87
  def self.description
@@ -44,6 +44,7 @@ module Fastlane
44
44
  connection.post(distribute_url(release_name), payload.to_json) do |request|
45
45
  request.headers[AUTHORIZATION] = "Bearer " + @auth_token
46
46
  request.headers[CONTENT_TYPE] = APPLICATION_JSON
47
+ request.headers[CLIENT_VERSION] = client_version_header_value
47
48
  end
48
49
  rescue Faraday::ClientError
49
50
  UI.user_error!("#{ErrorMessage::INVALID_TESTERS} \nEmails: #{emails} \nGroup Aliases: #{group_aliases}")
@@ -74,6 +75,7 @@ module Fastlane
74
75
  connection.patch(update_release_notes_url(release_name), payload.to_json) do |request|
75
76
  request.headers[AUTHORIZATION] = "Bearer " + @auth_token
76
77
  request.headers[CONTENT_TYPE] = APPLICATION_JSON
78
+ request.headers[CLIENT_VERSION] = client_version_header_value
77
79
  end
78
80
  rescue Faraday::ClientError => e
79
81
  error = ErrorResponse.new(e.response)
@@ -92,6 +94,7 @@ module Fastlane
92
94
  begin
93
95
  response = connection.get(aab_info_url(app_name)) do |request|
94
96
  request.headers[AUTHORIZATION] = "Bearer " + @auth_token
97
+ request.headers[CLIENT_VERSION] = client_version_header_value
95
98
  end
96
99
  rescue Faraday::ResourceNotFound
97
100
  UI.user_error!("#{ErrorMessage::INVALID_APP_ID}: #{app_name}")
@@ -171,7 +174,7 @@ module Fastlane
171
174
  UI.crash!("It took longer than expected to process your #{binary_type}, please try again.")
172
175
  end
173
176
 
174
- upload_status_response.release_name
177
+ upload_status_response
175
178
  end
176
179
 
177
180
  # Fetches the status of an uploaded binary
@@ -183,6 +186,7 @@ module Fastlane
183
186
  def get_upload_status(operation_name)
184
187
  response = connection.get(upload_status_url(operation_name)) do |request|
185
188
  request.headers[AUTHORIZATION] = "Bearer " + @auth_token
189
+ request.headers[CLIENT_VERSION] = client_version_header_value
186
190
  end
187
191
  UploadStatusResponse.new(response.body)
188
192
  end
@@ -197,6 +201,7 @@ module Fastlane
197
201
  begin
198
202
  response = connection.get(get_udids_url(app_id)) do |request|
199
203
  request.headers[AUTHORIZATION] = "Bearer " + @auth_token
204
+ request.headers[CLIENT_VERSION] = client_version_header_value
200
205
  end
201
206
  rescue Faraday::ResourceNotFound
202
207
  UI.user_error!("#{ErrorMessage::INVALID_APP_ID}: #{app_id}")
@@ -31,6 +31,18 @@ class UploadStatusResponse
31
31
  end
32
32
  end
33
33
 
34
+ def firebase_console_uri
35
+ release ? release[:firebaseConsoleUri] : nil
36
+ end
37
+
38
+ def testing_uri
39
+ release ? release[:testingUri] : nil
40
+ end
41
+
42
+ def binary_download_uri
43
+ release ? release[:binaryDownloadUri] : nil
44
+ end
45
+
34
46
  def status
35
47
  response ? response[:result] : nil
36
48
  end
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module FirebaseAppDistribution
3
- VERSION = "0.3.8"
3
+ VERSION = "0.4.0.pre.2"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane-plugin-firebase_app_distribution
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.8
4
+ version: 0.4.0.pre.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stefan Natchev
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2022-12-10 00:00:00.000000000 Z
13
+ date: 2023-01-19 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: pry
@@ -180,9 +180,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
180
180
  version: '0'
181
181
  required_rubygems_version: !ruby/object:Gem::Requirement
182
182
  requirements:
183
- - - ">="
183
+ - - ">"
184
184
  - !ruby/object:Gem::Version
185
- version: '0'
185
+ version: 1.3.1
186
186
  requirements: []
187
187
  rubygems_version: 3.1.6
188
188
  signing_key: