fastlane 2.128.0 → 2.132.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/README.md +64 -64
- data/cert/lib/cert/module.rb +2 -0
- data/cert/lib/cert/options.rb +6 -0
- data/cert/lib/cert/runner.rb +17 -11
- data/deliver/lib/deliver/submit_for_review.rb +1 -1
- data/fastlane/lib/fastlane.rb +4 -1
- data/fastlane/lib/fastlane/actions/.hockey.rb.swp +0 -0
- data/fastlane/lib/fastlane/actions/.slack.rb.swp +0 -0
- data/fastlane/lib/fastlane/actions/.update_project_provisioning.rb.swp +0 -0
- data/fastlane/lib/fastlane/actions/actions_helper.rb +4 -0
- data/fastlane/lib/fastlane/actions/app_store_build_number.rb +11 -3
- data/fastlane/lib/fastlane/actions/appetize_viewing_url_generator.rb +1 -1
- data/fastlane/lib/fastlane/actions/automatic_code_signing.rb +1 -1
- data/fastlane/lib/fastlane/actions/carthage.rb +4 -3
- data/fastlane/lib/fastlane/actions/commit_github_file.rb +1 -1
- data/fastlane/lib/fastlane/actions/copy_artifacts.rb +1 -1
- data/fastlane/lib/fastlane/actions/danger.rb +7 -0
- data/fastlane/lib/fastlane/actions/docs/sync_code_signing.md +23 -4
- data/fastlane/lib/fastlane/actions/download_dsyms.rb +35 -9
- data/fastlane/lib/fastlane/actions/ensure_env_vars.rb +58 -0
- data/fastlane/lib/fastlane/actions/get_version_number.rb +21 -2
- data/fastlane/lib/fastlane/actions/github_api.rb +1 -1
- data/fastlane/lib/fastlane/actions/gradle.rb +37 -8
- data/fastlane/lib/fastlane/actions/import_from_git.rb +1 -1
- data/fastlane/lib/fastlane/actions/onesignal.rb +59 -29
- data/fastlane/lib/fastlane/actions/pod_push.rb +29 -10
- data/fastlane/lib/fastlane/actions/puts.rb +1 -1
- data/fastlane/lib/fastlane/actions/register_devices.rb +38 -22
- data/fastlane/lib/fastlane/actions/resign.rb +2 -2
- data/fastlane/lib/fastlane/actions/slather.rb +1 -0
- data/fastlane/lib/fastlane/actions/sonar.rb +18 -0
- data/fastlane/lib/fastlane/actions/update_fastlane.rb +1 -1
- data/fastlane/lib/fastlane/commands_generator.rb +17 -1
- data/fastlane/lib/fastlane/fast_file.rb +7 -2
- data/fastlane/lib/fastlane/helper/adb_helper.rb +5 -0
- data/fastlane/lib/fastlane/helper/crashlytics_helper.rb +12 -6
- data/fastlane/lib/fastlane/plugins/plugin_manager.rb +2 -0
- data/fastlane/lib/fastlane/plugins/template/.rubocop.yml +3 -0
- data/fastlane/lib/fastlane/setup/setup_android.rb +1 -1
- data/fastlane/lib/fastlane/swift_fastlane_api_generator.rb +116 -32
- data/fastlane/lib/fastlane/swift_fastlane_function.rb +11 -7
- data/fastlane/lib/fastlane/swift_runner_upgrader.rb +4 -0
- data/fastlane/lib/fastlane/version.rb +1 -1
- data/fastlane/swift/Actions.swift +15 -0
- data/fastlane/swift/Deliverfile.swift +1 -1
- data/fastlane/swift/Fastlane.swift +341 -294
- data/fastlane/swift/FastlaneSwiftRunner/FastlaneSwiftRunner.xcodeproj/project.pbxproj +9 -0
- data/fastlane/swift/FastlaneSwiftRunner/FastlaneSwiftRunner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +8 -0
- data/fastlane/swift/FastlaneSwiftRunner/FastlaneSwiftRunner.xcodeproj/project.xcworkspace/xcuserdata/josh.xcuserdatad/UserInterfaceState.xcuserstate +0 -0
- data/fastlane/swift/Gymfile.swift +1 -1
- data/fastlane/swift/GymfileProtocol.swift +13 -11
- data/fastlane/swift/Matchfile.swift +1 -1
- data/fastlane/swift/MatchfileProtocol.swift +7 -1
- data/fastlane/swift/Plugins.swift +15 -0
- data/fastlane/swift/Precheckfile.swift +1 -1
- data/fastlane/swift/Scanfile.swift +1 -1
- data/fastlane/swift/ScanfileProtocol.swift +3 -3
- data/fastlane/swift/Screengrabfile.swift +1 -1
- data/fastlane/swift/Snapshotfile.swift +1 -1
- data/fastlane/swift/SnapshotfileProtocol.swift +3 -1
- data/fastlane/swift/upgrade_manifest.json +1 -1
- data/fastlane_core/lib/fastlane_core/analytics/analytics_event_builder.rb +1 -1
- data/fastlane_core/lib/fastlane_core/command_executor.rb +1 -1
- data/fastlane_core/lib/fastlane_core/configuration/config_item.rb +1 -1
- data/fastlane_core/lib/fastlane_core/helper.rb +1 -1
- data/fastlane_core/lib/fastlane_core/itunes_transporter.rb +1 -3
- data/fastlane_core/lib/fastlane_core/ui/implementations/shell.rb +3 -2
- data/frameit/lib/frameit/editor.rb +1 -1
- data/frameit/lib/frameit/screenshot.rb +4 -0
- data/gym/lib/gym/.runner.rb.swp +0 -0
- data/gym/lib/gym/generators/build_command_generator.rb +5 -1
- data/gym/lib/gym/options.rb +17 -17
- data/gym/lib/gym/runner.rb +33 -5
- data/match/lib/match/generator.rb +1 -0
- data/match/lib/match/importer.rb +1 -1
- data/match/lib/match/module.rb +2 -0
- data/match/lib/match/nuke.rb +6 -6
- data/match/lib/match/options.rb +17 -0
- data/match/lib/match/runner.rb +13 -9
- data/match/lib/match/storage/git_storage.rb +8 -2
- data/match/lib/match/storage/google_cloud_storage.rb +82 -33
- data/match/lib/match/storage/interface.rb +1 -1
- data/pilot/lib/pilot/.manager.rb.swp +0 -0
- data/produce/lib/produce/service.rb +7 -1
- data/scan/lib/scan/options.rb +1 -1
- data/scan/lib/scan/runner.rb +1 -1
- data/sigh/lib/sigh/download_all.rb +48 -8
- data/sigh/lib/sigh/runner.rb +13 -5
- data/snapshot/lib/assets/SnapshotHelper.swift +3 -3
- data/snapshot/lib/snapshot/commands_generator.rb +2 -2
- data/snapshot/lib/snapshot/options.rb +5 -0
- data/snapshot/lib/snapshot/reports_generator.rb +3 -0
- data/snapshot/lib/snapshot/simulator_launchers/launcher_configuration.rb +2 -0
- data/snapshot/lib/snapshot/simulator_launchers/simulator_launcher.rb +1 -1
- data/snapshot/lib/snapshot/simulator_launchers/simulator_launcher_base.rb +16 -1
- data/snapshot/lib/snapshot/update.rb +4 -2
- data/spaceship/lib/spaceship/client.rb +1 -1
- data/spaceship/lib/spaceship/connect_api/.DS_Store +0 -0
- data/spaceship/lib/spaceship/connect_api/models/app.rb +6 -6
- data/spaceship/lib/spaceship/connect_api/models/beta_tester_metric.rb +1 -0
- data/spaceship/lib/spaceship/connect_api/models/build.rb +3 -3
- data/spaceship/lib/spaceship/connect_api/models/build_delivery.rb +1 -1
- data/spaceship/lib/spaceship/connect_api/models/bundle_id.rb +1 -1
- data/spaceship/lib/spaceship/connect_api/models/certificate.rb +1 -1
- data/spaceship/lib/spaceship/connect_api/models/device.rb +1 -1
- data/spaceship/lib/spaceship/connect_api/models/profile.rb +1 -1
- data/spaceship/lib/spaceship/du/du_client.rb +4 -0
- data/spaceship/lib/spaceship/portal/.certificate.rb.swp +0 -0
- data/spaceship/lib/spaceship/portal/certificate.rb +15 -1
- data/spaceship/lib/spaceship/portal/provisioning_profile.rb +1 -1
- data/spaceship/lib/spaceship/spaceauth_runner.rb +1 -1
- data/spaceship/lib/spaceship/test_flight/tester.rb +1 -1
- data/spaceship/lib/spaceship/tunes/app_version.rb +4 -0
- data/spaceship/lib/spaceship/tunes/application.rb +4 -0
- data/spaceship/lib/spaceship/tunes/availability.rb +40 -8
- data/spaceship/lib/spaceship/tunes/b2b_organization.rb +50 -0
- data/spaceship/lib/spaceship/tunes/build_details.rb +160 -18
- data/spaceship/lib/spaceship/tunes/display_family.rb +3 -3
- data/spaceship/lib/spaceship/tunes/iap.rb +2 -0
- data/spaceship/lib/spaceship/tunes/iap_detail.rb +17 -0
- data/spaceship/lib/spaceship/tunes/iap_family_details.rb +10 -2
- data/spaceship/lib/spaceship/tunes/tunes_client.rb +63 -2
- data/supply/lib/supply/client.rb +1 -1
- metadata +59 -45
data/scan/lib/scan/runner.rb
CHANGED
@@ -136,7 +136,7 @@ module Scan
|
|
136
136
|
# Zips build products and moves it to output directory
|
137
137
|
UI.message("Zipping build products")
|
138
138
|
FastlaneCore::Helper.zip_directory(path, output_path, contents_only: true, overwrite: true, print: false)
|
139
|
-
UI.message("
|
139
|
+
UI.message("Successfully zipped build products: #{output_path}")
|
140
140
|
end
|
141
141
|
|
142
142
|
def test_results
|
@@ -12,7 +12,42 @@ module Sigh
|
|
12
12
|
Spaceship.select_team
|
13
13
|
UI.message("Successfully logged in")
|
14
14
|
|
15
|
-
|
15
|
+
case Sigh.config[:platform].to_s
|
16
|
+
when 'ios'
|
17
|
+
download_profiles(Spaceship.provisioning_profile.all(xcode: download_xcode_profiles))
|
18
|
+
xcode_profiles_downloaded?(xcode: download_xcode_profiles, supported: true)
|
19
|
+
when 'macos'
|
20
|
+
download_profiles(Spaceship.provisioning_profile.all(mac: true, xcode: download_xcode_profiles))
|
21
|
+
xcode_profiles_downloaded?(xcode: download_xcode_profiles, supported: true)
|
22
|
+
when 'tvos'
|
23
|
+
download_profiles(Spaceship.provisioning_profile.all_tvos)
|
24
|
+
xcode_profiles_downloaded?(xcode: download_xcode_profiles, supported: false)
|
25
|
+
end
|
26
|
+
end
|
27
|
+
|
28
|
+
# @param xcode [Bool] Whether or not the user passed the download_xcode_profiles flag
|
29
|
+
# @param supported [Bool] Whether or not this platform supports downloading xcode profiles at all
|
30
|
+
def xcode_profiles_downloaded?(xcode: false, supported: false)
|
31
|
+
if supported
|
32
|
+
if xcode
|
33
|
+
UI.message("This run also included all Xcode managed provisioning profiles, as you used the `--download_xcode_profiles` flag")
|
34
|
+
elsif !xcode
|
35
|
+
UI.message("All Xcode managed provisioning profiles were ignored on this, to include them use the `--download_xcode_profiles` flag")
|
36
|
+
end
|
37
|
+
|
38
|
+
elsif !supported
|
39
|
+
if xcode
|
40
|
+
UI.important("Downloading Xcode managed profiles is not supported for platform #{Sigh.config[:platform]}")
|
41
|
+
return
|
42
|
+
end
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
# @param profiles [Array] Array of all the provisioning profiles we want to download
|
47
|
+
def download_profiles(profiles)
|
48
|
+
UI.important("No profiles available for download") if profiles.empty?
|
49
|
+
|
50
|
+
profiles.each do |profile|
|
16
51
|
if profile.valid?
|
17
52
|
UI.message("Downloading profile '#{profile.name}'...")
|
18
53
|
download_profile(profile)
|
@@ -20,19 +55,24 @@ module Sigh
|
|
20
55
|
UI.important("Skipping invalid/expired profile '#{profile.name}'")
|
21
56
|
end
|
22
57
|
end
|
23
|
-
|
24
|
-
if download_xcode_profiles
|
25
|
-
UI.message("This run also included all Xcode managed provisioning profiles, as you used the `--download_xcode_profiles` flag")
|
26
|
-
else
|
27
|
-
UI.message("All Xcode managed provisioning profiles were ignored on this, to include them use the `--download_xcode_profiles` flag")
|
28
|
-
end
|
29
58
|
end
|
30
59
|
|
60
|
+
# @param profile [ProvisioningProfile] A profile we plan to download and store
|
31
61
|
def download_profile(profile)
|
32
62
|
FileUtils.mkdir_p(Sigh.config[:output_path])
|
33
63
|
|
34
64
|
type_name = profile.class.pretty_type
|
35
|
-
profile_name = "#{type_name}_#{profile.uuid}_#{profile.app.bundle_id}
|
65
|
+
profile_name = "#{type_name}_#{profile.uuid}_#{profile.app.bundle_id}"
|
66
|
+
|
67
|
+
if Sigh.config[:platform].to_s == 'tvos'
|
68
|
+
profile_name += "_tvos"
|
69
|
+
end
|
70
|
+
|
71
|
+
if Sigh.config[:platform].to_s == 'macos'
|
72
|
+
profile_name += '.provisionprofile'
|
73
|
+
else
|
74
|
+
profile_name += '.mobileprovision'
|
75
|
+
end
|
36
76
|
|
37
77
|
output_path = File.join(Sigh.config[:output_path], profile_name)
|
38
78
|
File.open(output_path, "wb") do |f|
|
data/sigh/lib/sigh/runner.rb
CHANGED
@@ -155,27 +155,35 @@ module Sigh
|
|
155
155
|
case Sigh.config[:platform].to_s
|
156
156
|
when 'ios', 'tvos'
|
157
157
|
if profile_type == Spaceship.provisioning_profile.Development
|
158
|
-
certificates = Spaceship.certificate.development.all
|
158
|
+
certificates = Spaceship.certificate.development.all +
|
159
|
+
Spaceship.certificate.apple_development.all
|
159
160
|
elsif profile_type == Spaceship.provisioning_profile.InHouse
|
161
|
+
# Enterprise accounts don't have access to Apple Distribution certificates
|
160
162
|
certificates = Spaceship.certificate.in_house.all
|
161
163
|
# handles case where the desired certificate type is adhoc but the account is an enterprise account
|
162
164
|
# the apple dev portal api has a weird quirk in it where if you query for distribution certificates
|
163
165
|
# for enterprise accounts, you get nothing back even if they exist.
|
164
166
|
elsif profile_type == Spaceship.provisioning_profile.AdHoc && Spaceship.client && Spaceship.client.in_house?
|
167
|
+
# Enterprise accounts don't have access to Apple Distribution certificates
|
165
168
|
certificates = Spaceship.certificate.in_house.all
|
166
169
|
else
|
167
|
-
|
170
|
+
# Ad hoc or App Store
|
171
|
+
certificates = Spaceship.certificate.production.all +
|
172
|
+
Spaceship.certificate.apple_distribution.all
|
168
173
|
end
|
169
174
|
|
170
175
|
when 'macos'
|
171
176
|
if profile_type == Spaceship.provisioning_profile.Development
|
172
|
-
certificates = Spaceship.certificate.mac_development.all
|
177
|
+
certificates = Spaceship.certificate.mac_development.all +
|
178
|
+
Spaceship.certificate.apple_development.all
|
173
179
|
elsif profile_type == Spaceship.provisioning_profile.AppStore
|
174
|
-
certificates = Spaceship.certificate.mac_app_distribution.all
|
180
|
+
certificates = Spaceship.certificate.mac_app_distribution.all +
|
181
|
+
Spaceship.certificate.apple_distribution.all
|
175
182
|
elsif profile_type == Spaceship.provisioning_profile.Direct
|
176
183
|
certificates = Spaceship.certificate.developer_id_application.all
|
177
184
|
else
|
178
|
-
certificates = Spaceship.certificate.mac_app_distribution.all
|
185
|
+
certificates = Spaceship.certificate.mac_app_distribution.all +
|
186
|
+
Spaceship.certificate.apple_distribution.all
|
179
187
|
end
|
180
188
|
end
|
181
189
|
|
@@ -175,11 +175,11 @@ open class Snapshot: NSObject {
|
|
175
175
|
|
176
176
|
let screenshot = XCUIScreen.main.screenshot()
|
177
177
|
guard var simulator = ProcessInfo().environment["SIMULATOR_DEVICE_NAME"], let screenshotsDir = screenshotsDirectory else { return }
|
178
|
-
|
178
|
+
|
179
179
|
do {
|
180
180
|
// The simulator name contains "Clone X of " inside the screenshot file when running parallelized UI Tests on concurrent devices
|
181
181
|
let regex = try NSRegularExpression(pattern: "Clone [0-9]+ of ")
|
182
|
-
let range =
|
182
|
+
let range = NSRange(location: 0, length: simulator.count)
|
183
183
|
simulator = regex.stringByReplacingMatches(in: simulator, range: range, withTemplate: "")
|
184
184
|
|
185
185
|
let path = screenshotsDir.appendingPathComponent("\(simulator)-\(name).png")
|
@@ -300,4 +300,4 @@ private extension CGFloat {
|
|
300
300
|
|
301
301
|
// Please don't remove the lines below
|
302
302
|
// They are used to detect outdated configuration files
|
303
|
-
// SnapshotHelperVersion [1.
|
303
|
+
// SnapshotHelperVersion [1.21]
|
@@ -56,10 +56,10 @@ module Snapshot
|
|
56
56
|
command :update do |c|
|
57
57
|
c.syntax = 'fastlane snapshot update'
|
58
58
|
c.description = "Updates your SnapshotHelper.swift to the latest version"
|
59
|
-
|
59
|
+
c.option('--force', 'Disables confirmation prompts')
|
60
60
|
c.action do |args, options|
|
61
61
|
require 'snapshot/update'
|
62
|
-
Snapshot::Update.new.update
|
62
|
+
Snapshot::Update.new.update(force: options.force)
|
63
63
|
end
|
64
64
|
end
|
65
65
|
|
@@ -116,6 +116,11 @@ module Snapshot
|
|
116
116
|
description: "Enabling this option will configure the Simulator's system language",
|
117
117
|
default_value: false,
|
118
118
|
is_string: false),
|
119
|
+
FastlaneCore::ConfigItem.new(key: :dark_mode,
|
120
|
+
env_name: 'SNAPSHOT_DARK_MODE',
|
121
|
+
description: "Enabling this option will configure the Simulator to be in dark mode (false for light, true for dark)",
|
122
|
+
optional: true,
|
123
|
+
type: Boolean),
|
119
124
|
FastlaneCore::ConfigItem.new(key: :app_identifier,
|
120
125
|
env_name: 'SNAPSHOT_APP_IDENTIFIER',
|
121
126
|
short_option: "-a",
|
@@ -77,6 +77,9 @@ module Snapshot
|
|
77
77
|
{
|
78
78
|
# snapshot in Xcode 9 saves screenshots with the SIMULATOR_DEVICE_NAME
|
79
79
|
# which includes spaces
|
80
|
+
'iPhone 11 Pro Max' => "iPhone 11 Pro Max",
|
81
|
+
'iPhone 11 Pro' => "iPhone 11 Pro",
|
82
|
+
'iPhone 11' => "iPhone 11",
|
80
83
|
'iPhone XS Max' => "iPhone XS Max",
|
81
84
|
'iPhone XS' => "iPhone XS",
|
82
85
|
'iPhone XR' => "iPhone XR",
|
@@ -8,6 +8,7 @@ module Snapshot
|
|
8
8
|
attr_accessor :clean
|
9
9
|
attr_accessor :erase_simulator
|
10
10
|
attr_accessor :localize_simulator
|
11
|
+
attr_accessor :dark_mode
|
11
12
|
attr_accessor :reinstall_app
|
12
13
|
attr_accessor :app_identifier
|
13
14
|
|
@@ -32,6 +33,7 @@ module Snapshot
|
|
32
33
|
@clean = snapshot_config[:clean]
|
33
34
|
@erase_simulator = snapshot_config[:erase_simulator]
|
34
35
|
@localize_simulator = snapshot_config[:localize_simulator]
|
36
|
+
@dark_mode = snapshot_config[:dark_mode]
|
35
37
|
@reinstall_app = snapshot_config[:reinstall_app]
|
36
38
|
@app_identifier = snapshot_config[:app_identifier]
|
37
39
|
@number_of_retries = snapshot_config[:number_of_retries]
|
@@ -190,7 +190,7 @@ module Snapshot
|
|
190
190
|
hash[name] = ["No tests were executed"]
|
191
191
|
else
|
192
192
|
tests = Array(summary.data.first[:tests])
|
193
|
-
hash[name] = tests.
|
193
|
+
hash[name] = tests.flat_map { |test| Array(test[:failures]).map { |failure| failure[:failure_message] } }
|
194
194
|
end
|
195
195
|
end
|
196
196
|
end
|
@@ -55,11 +55,14 @@ module Snapshot
|
|
55
55
|
Fixes::HardwareKeyboardFix.patch
|
56
56
|
|
57
57
|
device_types.each do |type|
|
58
|
-
if launcher_config.erase_simulator || launcher_config.localize_simulator
|
58
|
+
if launcher_config.erase_simulator || launcher_config.localize_simulator || !launcher_config.dark_mode.nil?
|
59
59
|
erase_simulator(type)
|
60
60
|
if launcher_config.localize_simulator
|
61
61
|
localize_simulator(type, language, locale)
|
62
62
|
end
|
63
|
+
unless launcher_config.dark_mode.nil?
|
64
|
+
interface_style(type, launcher_config.dark_mode)
|
65
|
+
end
|
63
66
|
elsif launcher_config.reinstall_app
|
64
67
|
# no need to reinstall if device has been erased
|
65
68
|
uninstall_app(type)
|
@@ -124,6 +127,18 @@ module Snapshot
|
|
124
127
|
end
|
125
128
|
end
|
126
129
|
|
130
|
+
def interface_style(device_type, dark_mode)
|
131
|
+
device_udid = TestCommandGenerator.device_udid(device_type)
|
132
|
+
if device_udid
|
133
|
+
plist = {
|
134
|
+
UserInterfaceStyleMode: (dark_mode ? 2 : 1)
|
135
|
+
}
|
136
|
+
UI.message("Setting interface style #{device_type} (UserInterfaceStyleMode=#{dark_mode})")
|
137
|
+
plist_path = "#{ENV['HOME']}/Library/Developer/CoreSimulator/Devices/#{device_udid}/data/Library/Preferences/com.apple.uikitservices.userInterfaceStyleMode.plist"
|
138
|
+
File.write(plist_path, Plist::Emit.dump(plist))
|
139
|
+
end
|
140
|
+
end
|
141
|
+
|
127
142
|
def copy_simulator_logs(device_names, language, locale, launch_arguments)
|
128
143
|
return unless launcher_config.output_simulator_logs
|
129
144
|
|
@@ -11,7 +11,7 @@ module Snapshot
|
|
11
11
|
paths.reject { |p| p.include?("snapshot/lib/assets/") }
|
12
12
|
end
|
13
13
|
|
14
|
-
def update
|
14
|
+
def update(force: false)
|
15
15
|
paths = self.class.find_helper
|
16
16
|
UI.user_error!("Couldn't find any SnapshotHelper files in current directory") if paths.count == 0
|
17
17
|
|
@@ -22,7 +22,9 @@ module Snapshot
|
|
22
22
|
UI.message("The underlying API will not change. You can always migrate manually by looking at")
|
23
23
|
UI.message("https://github.com/fastlane/fastlane/blob/master/snapshot/lib/assets/SnapshotHelper.swift")
|
24
24
|
|
25
|
-
|
25
|
+
if !force && !UI.confirm("Overwrite configuration files?")
|
26
|
+
return 1
|
27
|
+
end
|
26
28
|
|
27
29
|
paths.each do |path|
|
28
30
|
UI.message("Updating '#{path}'...")
|
@@ -738,7 +738,7 @@ module Spaceship
|
|
738
738
|
raise InternalServerError, "Received an internal server error from App Store Connect / Developer Portal, please try again later"
|
739
739
|
elsif body.to_s.include?("Gateway Timeout - In read")
|
740
740
|
raise GatewayTimeoutError, "Received a gateway timeout error from App Store Connect / Developer Portal, please try again later"
|
741
|
-
elsif (body["
|
741
|
+
elsif (body["userString"] || "").include?("Program License Agreement")
|
742
742
|
raise ProgramLicenseAgreementUpdated, "#{body['userString']} Please manually log into your Apple Developer account to review and accept the updated agreement."
|
743
743
|
end
|
744
744
|
end
|
Binary file
|
@@ -32,7 +32,7 @@ module Spaceship
|
|
32
32
|
|
33
33
|
def self.all(filter: {}, includes: nil, limit: nil, sort: nil)
|
34
34
|
resps = Spaceship::ConnectAPI.get_apps(filter: filter, includes: includes, limit: limit, sort: sort).all_pages
|
35
|
-
return resps.
|
35
|
+
return resps.flat_map(&:to_models)
|
36
36
|
end
|
37
37
|
|
38
38
|
def self.find(bundle_id)
|
@@ -54,7 +54,7 @@ module Spaceship
|
|
54
54
|
filter[:apps] = id
|
55
55
|
|
56
56
|
resps = Spaceship::ConnectAPI.get_beta_testers(filter: filter, includes: includes, limit: limit, sort: sort).all_pages
|
57
|
-
return resps.
|
57
|
+
return resps.flat_map(&:to_models)
|
58
58
|
end
|
59
59
|
|
60
60
|
#
|
@@ -66,7 +66,7 @@ module Spaceship
|
|
66
66
|
filter[:app] = id
|
67
67
|
|
68
68
|
resps = Spaceship::ConnectAPI.get_builds(filter: filter, includes: includes, limit: limit, sort: sort).all_pages
|
69
|
-
return resps.
|
69
|
+
return resps.flat_map(&:to_models)
|
70
70
|
end
|
71
71
|
|
72
72
|
def get_build_deliveries(filter: {}, includes: nil, limit: nil, sort: nil)
|
@@ -74,7 +74,7 @@ module Spaceship
|
|
74
74
|
filter[:app] = id
|
75
75
|
|
76
76
|
resps = Spaceship::ConnectAPI.get_build_deliveries(filter: filter, includes: includes, limit: limit, sort: sort).all_pages
|
77
|
-
return resps.
|
77
|
+
return resps.flat_map(&:to_models)
|
78
78
|
end
|
79
79
|
|
80
80
|
def get_beta_app_localizations(filter: {}, includes: nil, limit: nil, sort: nil)
|
@@ -82,7 +82,7 @@ module Spaceship
|
|
82
82
|
filter[:app] = id
|
83
83
|
|
84
84
|
resps = Spaceship::ConnectAPI.get_beta_app_localizations(filter: filter, includes: includes, limit: limit, sort: sort).all_pages
|
85
|
-
return resps.
|
85
|
+
return resps.flat_map(&:to_models)
|
86
86
|
end
|
87
87
|
|
88
88
|
def get_beta_groups(filter: {}, includes: nil, limit: nil, sort: nil)
|
@@ -90,7 +90,7 @@ module Spaceship
|
|
90
90
|
filter[:app] = id
|
91
91
|
|
92
92
|
resps = Spaceship::ConnectAPI.get_beta_groups(filter: filter, includes: includes, limit: limit, sort: sort).all_pages
|
93
|
-
return resps.
|
93
|
+
return resps.flat_map(&:to_models)
|
94
94
|
end
|
95
95
|
end
|
96
96
|
end
|
@@ -109,7 +109,7 @@ module Spaceship
|
|
109
109
|
sort: sort,
|
110
110
|
limit: limit
|
111
111
|
).all_pages
|
112
|
-
models = resps.
|
112
|
+
models = resps.flat_map(&:to_models)
|
113
113
|
|
114
114
|
# Filtering after models are fetched since there is no way to do this in a query param filter
|
115
115
|
if platform
|
@@ -138,7 +138,7 @@ module Spaceship
|
|
138
138
|
sort: sort,
|
139
139
|
limit: limit
|
140
140
|
).all_pages
|
141
|
-
return resps.
|
141
|
+
return resps.flat_map(&:to_models)
|
142
142
|
end
|
143
143
|
|
144
144
|
def get_build_beta_details(filter: {}, includes: nil, limit: nil, sort: nil)
|
@@ -148,7 +148,7 @@ module Spaceship
|
|
148
148
|
sort: sort,
|
149
149
|
limit: limit
|
150
150
|
).all_pages
|
151
|
-
return resps.
|
151
|
+
return resps.flat_map(&:to_models)
|
152
152
|
end
|
153
153
|
|
154
154
|
def post_beta_app_review_submission
|
@@ -35,7 +35,7 @@ module Spaceship
|
|
35
35
|
|
36
36
|
def self.all(filter: {}, includes: nil, limit: nil, sort: nil)
|
37
37
|
resps = Spaceship::ConnectAPI.get_bundle_ids(filter: filter, includes: includes).all_pages
|
38
|
-
return resps.
|
38
|
+
return resps.flat_map(&:to_models)
|
39
39
|
end
|
40
40
|
|
41
41
|
def self.get(bundle_id_id: nil, includes: nil)
|
@@ -41,7 +41,7 @@ module Spaceship
|
|
41
41
|
|
42
42
|
def self.all(filter: {}, includes: nil, limit: nil, sort: nil)
|
43
43
|
resps = Spaceship::ConnectAPI.get_certificates(filter: filter, includes: includes).all_pages
|
44
|
-
return resps.
|
44
|
+
return resps.flat_map(&:to_models)
|
45
45
|
end
|
46
46
|
end
|
47
47
|
end
|
@@ -46,7 +46,7 @@ module Spaceship
|
|
46
46
|
|
47
47
|
def self.all(filter: {}, includes: nil, limit: nil, sort: nil)
|
48
48
|
resps = Spaceship::ConnectAPI.get_devices(filter: filter, includes: includes).all_pages
|
49
|
-
return resps.
|
49
|
+
return resps.flat_map(&:to_models)
|
50
50
|
end
|
51
51
|
end
|
52
52
|
end
|
@@ -53,7 +53,7 @@ module Spaceship
|
|
53
53
|
|
54
54
|
def self.all(filter: {}, includes: nil, limit: nil, sort: nil)
|
55
55
|
resps = Spaceship::ConnectAPI.get_profiles(filter: filter, includes: includes).all_pages
|
56
|
-
return resps.
|
56
|
+
return resps.flat_map(&:to_models)
|
57
57
|
end
|
58
58
|
end
|
59
59
|
end
|
@@ -22,6 +22,10 @@ module Spaceship
|
|
22
22
|
upload_file(app_version: app_version, upload_file: upload_file, path: '/upload/image', content_provider_id: content_provider_id, sso_token: sso_token_for_image, du_validation_rule_set: screenshot_picture_type(device, is_messages))
|
23
23
|
end
|
24
24
|
|
25
|
+
def upload_purchase_merch_screenshot(app_id, upload_file, content_provider_id, sso_token_for_image)
|
26
|
+
upload_file(app_id: app_id, upload_file: upload_file, path: '/upload/image', content_provider_id: content_provider_id, sso_token: sso_token_for_image, du_validation_rule_set: 'MZPFT.MerchandisingIAPIcon')
|
27
|
+
end
|
28
|
+
|
25
29
|
def upload_purchase_review_screenshot(app_id, upload_file, content_provider_id, sso_token_for_image)
|
26
30
|
upload_file(app_id: app_id, upload_file: upload_file, path: '/upload/image', content_provider_id: content_provider_id, sso_token: sso_token_for_image, du_validation_rule_set: get_picture_type(upload_file))
|
27
31
|
end
|
Binary file
|
@@ -89,6 +89,12 @@ module Spaceship
|
|
89
89
|
# Certs are not associated with apps
|
90
90
|
#####################################################
|
91
91
|
|
92
|
+
# An Apple development code signing certificate used for development environment
|
93
|
+
class AppleDevelopment < Certificate; end
|
94
|
+
|
95
|
+
# An Apple distribution code signing certificate used for distribution environment
|
96
|
+
class AppleDistribution < Certificate; end
|
97
|
+
|
92
98
|
# A development code signing certificate used for development environment
|
93
99
|
class Development < Certificate; end
|
94
100
|
|
@@ -152,6 +158,11 @@ module Spaceship
|
|
152
158
|
# A Mac push notification certificate for production environment
|
153
159
|
class MacProductionPush < PushCertificate; end
|
154
160
|
|
161
|
+
APPLE_CERTIFICATE_TYPE_IDS = {
|
162
|
+
"83Q87W3TGH" => AppleDevelopment,
|
163
|
+
"WXV89964HE" => AppleDistribution
|
164
|
+
}
|
165
|
+
|
155
166
|
IOS_CERTIFICATE_TYPE_IDS = {
|
156
167
|
"5QPB9NHCEI" => Development,
|
157
168
|
"R58UK2EWSO" => Production,
|
@@ -187,7 +198,9 @@ module Spaceship
|
|
187
198
|
"DIVN2GW3XT" => DeveloperIdApplication
|
188
199
|
}
|
189
200
|
|
190
|
-
CERTIFICATE_TYPE_IDS =
|
201
|
+
CERTIFICATE_TYPE_IDS = APPLE_CERTIFICATE_TYPE_IDS
|
202
|
+
.merge(IOS_CERTIFICATE_TYPE_IDS)
|
203
|
+
.merge(MAC_CERTIFICATE_TYPE_IDS)
|
191
204
|
|
192
205
|
# Class methods
|
193
206
|
class << self
|
@@ -259,6 +272,7 @@ module Spaceship
|
|
259
272
|
def all(mac: false)
|
260
273
|
if self == Certificate # are we the base-class?
|
261
274
|
type_ids = mac ? MAC_CERTIFICATE_TYPE_IDS : IOS_CERTIFICATE_TYPE_IDS
|
275
|
+
type_ids = APPLE_CERTIFICATE_TYPE_IDS.merge(type_ids)
|
262
276
|
types = type_ids.keys
|
263
277
|
types += OLDER_IOS_CERTIFICATE_TYPES unless mac
|
264
278
|
else
|