fastlane-plugin-firebase_app_distribution 0.7.0 → 0.7.1.pre.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/fastlane/plugin/firebase_app_distribution/actions/firebase_app_distribution_action.rb +11 -5
- data/lib/fastlane/plugin/firebase_app_distribution/helper/firebase_app_distribution_helper.rb +5 -1
- data/lib/fastlane/plugin/firebase_app_distribution/version.rb +1 -1
- metadata +4 -18
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f18fcc30ef0dac6c2fc77d0813e51fc6b2c602e76e397c69aec31bbbdb69baf5
|
4
|
+
data.tar.gz: 00f4aa04fffd04807c931952908c2c885cb6b5b53a49a145e48b634225e130cc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ac9ef34ece7fece99ee759c4163585b58a96208ce3470a067446bca2fe99e769d85e48cd321d532369b7f15cdcbcc284eeccfe7147f8a8f65aa24e760337ddb7
|
7
|
+
data.tar.gz: 762d50b9e45c3ec08920c0cd6c8031da03786d3e6a48293053d89f540c0ee4d441fc45ce4c323a37b3f99d641a458e6fcedc2e077490b819ecadabc8e23dd065
|
data/lib/fastlane/plugin/firebase_app_distribution/actions/firebase_app_distribution_action.rb
CHANGED
@@ -28,15 +28,22 @@ module Fastlane
|
|
28
28
|
app_id = app_id_from_params(params)
|
29
29
|
app_name = app_name_from_app_id(app_id)
|
30
30
|
platform = lane_platform || platform_from_app_id(app_id)
|
31
|
+
timeout = get_upload_timeout(params)
|
31
32
|
|
32
33
|
binary_path = get_binary_path(platform, params)
|
33
34
|
UI.user_error!("Couldn't find binary") if binary_path.nil?
|
34
35
|
UI.user_error!("Couldn't find binary at path #{binary_path}") unless File.exist?(binary_path)
|
35
36
|
binary_type = binary_type_from_path(binary_path)
|
36
37
|
|
37
|
-
|
38
|
+
# TODO(lkellogg): This sets the send timeout for all POST requests made by the client, but
|
39
|
+
# ideally the timeout should only apply to the binary upload
|
40
|
+
client = init_client(params[:service_credentials_file],
|
41
|
+
params[:firebase_cli_token],
|
42
|
+
params[:debug],
|
43
|
+
timeout)
|
38
44
|
|
39
|
-
# If binary is an AAB, get the AAB info for this app, which includes the integration state
|
45
|
+
# If binary is an AAB, get the AAB info for this app, which includes the integration state
|
46
|
+
# and certificate data
|
40
47
|
if binary_type == :AAB
|
41
48
|
aab_info = get_aab_info(client, app_name)
|
42
49
|
validate_aab_setup!(aab_info)
|
@@ -44,8 +51,6 @@ module Fastlane
|
|
44
51
|
|
45
52
|
binary_type = binary_type_from_path(binary_path)
|
46
53
|
UI.message("⌛ Uploading the #{binary_type}.")
|
47
|
-
|
48
|
-
timeout = get_upload_timeout(params)
|
49
54
|
operation = upload_binary(app_name, binary_path, client, timeout)
|
50
55
|
release = poll_upload_release_operation(client, operation, binary_type)
|
51
56
|
|
@@ -242,12 +247,13 @@ module Fastlane
|
|
242
247
|
|
243
248
|
def self.upload_binary(app_name, binary_path, client, timeout)
|
244
249
|
options = Google::Apis::RequestOptions.new
|
245
|
-
options.max_elapsed_time = timeout
|
250
|
+
options.max_elapsed_time = timeout # includes retries (default = no retries)
|
246
251
|
options.header = {
|
247
252
|
'Content-Type' => 'application/octet-stream',
|
248
253
|
'X-Goog-Upload-File-Name' => File.basename(binary_path),
|
249
254
|
'X-Goog-Upload-Protocol' => 'raw'
|
250
255
|
}
|
256
|
+
|
251
257
|
# For some reason calling the client.upload_medium returns nil when
|
252
258
|
# it should return a long running operation object, so we make a
|
253
259
|
# standard http call instead and convert it to a long running object
|
data/lib/fastlane/plugin/firebase_app_distribution/helper/firebase_app_distribution_helper.rb
CHANGED
@@ -65,7 +65,7 @@ module Fastlane
|
|
65
65
|
"#{project_name(project_number)}/groups/#{group_alias}"
|
66
66
|
end
|
67
67
|
|
68
|
-
def init_client(service_credentials_file, firebase_cli_token, debug =
|
68
|
+
def init_client(service_credentials_file, firebase_cli_token, debug, timeout = nil)
|
69
69
|
if debug
|
70
70
|
UI.important("Warning: Debug logging enabled. Output may include sensitive information.")
|
71
71
|
Google::Apis.logger.level = Logger::DEBUG
|
@@ -73,6 +73,10 @@ module Fastlane
|
|
73
73
|
|
74
74
|
Google::Apis::ClientOptions.default.application_name = "fastlane"
|
75
75
|
Google::Apis::ClientOptions.default.application_version = Fastlane::FirebaseAppDistribution::VERSION
|
76
|
+
unless timeout.nil?
|
77
|
+
Google::Apis::ClientOptions.default.send_timeout_sec = timeout
|
78
|
+
end
|
79
|
+
|
76
80
|
client = Google::Apis::FirebaseappdistributionV1::FirebaseAppDistributionService.new
|
77
81
|
client.authorization = get_authorization(service_credentials_file, firebase_cli_token)
|
78
82
|
client
|
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.7.
|
4
|
+
version: 0.7.1.pre.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Stefan Natchev
|
@@ -10,22 +10,8 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2023-08-
|
13
|
+
date: 2023-08-02 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
|
-
- !ruby/object:Gem::Dependency
|
16
|
-
name: google-api-client
|
17
|
-
requirement: !ruby/object:Gem::Requirement
|
18
|
-
requirements:
|
19
|
-
- - "~>"
|
20
|
-
- !ruby/object:Gem::Version
|
21
|
-
version: '0.38'
|
22
|
-
type: :runtime
|
23
|
-
prerelease: false
|
24
|
-
version_requirements: !ruby/object:Gem::Requirement
|
25
|
-
requirements:
|
26
|
-
- - "~>"
|
27
|
-
- !ruby/object:Gem::Version
|
28
|
-
version: '0.38'
|
29
15
|
- !ruby/object:Gem::Dependency
|
30
16
|
name: google-apis-firebaseappdistribution_v1
|
31
17
|
requirement: !ruby/object:Gem::Requirement
|
@@ -206,9 +192,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
206
192
|
version: '0'
|
207
193
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
208
194
|
requirements:
|
209
|
-
- - "
|
195
|
+
- - ">"
|
210
196
|
- !ruby/object:Gem::Version
|
211
|
-
version:
|
197
|
+
version: 1.3.1
|
212
198
|
requirements: []
|
213
199
|
rubygems_version: 3.4.10
|
214
200
|
signing_key:
|