From 1990a9d2e6223994737d694e2f56232961ef8178 Mon Sep 17 00:00:00 2001 From: Mo Date: Thu, 7 Jul 2022 14:04:49 -0500 Subject: [PATCH] chore: mobile workflow --- packages/mobile/fastlane/Fastfile | 32 ++++++++++++++++++++----------- 1 file changed, 21 insertions(+), 11 deletions(-) diff --git a/packages/mobile/fastlane/Fastfile b/packages/mobile/fastlane/Fastfile index 5b15f7bf9..771e51c3a 100755 --- a/packages/mobile/fastlane/Fastfile +++ b/packages/mobile/fastlane/Fastfile @@ -46,15 +46,25 @@ platform :ios do is_prod = scheme == 'StandardNotes' - upload_to_testflight( - apple_id: ENV['APPLE_APP_ID'], - distribute_external: is_prod, - groups: ['Public'], - notify_external_testers: is_prod, - submit_beta_review: is_prod, - reject_build_waiting_for_review: is_prod, - changelog: 'Fixes and improvements.' - ) + begin + upload_to_testflight( + apple_id: ENV['APPLE_APP_ID'], + distribute_external: is_prod, + groups: ['Public'], + notify_external_testers: is_prod, + submit_beta_review: is_prod, + reject_build_waiting_for_review: is_prod, + changelog: 'Fixes and improvements.' + ) + + # https://github.com/fastlane/fastlane/issues/18408 + rescue Exception => e + if e.message.include? 'Another build is in review' + UI.important('Another build is already in external beta review. Skipping external beta review submission') + else + raise + end + end if is_prod upload_to_app_store( @@ -66,7 +76,7 @@ platform :ios do skip_screenshots: true, skip_binary_upload: true, release_notes: { - 'default': "Fixes and improvements.", + 'default': 'Fixes and improvements.' } ) end @@ -123,7 +133,7 @@ platform :android do end def deploy_android(variant, versionCode, track = 'beta') - sh("yarn run android:bundle") + sh('yarn run android:bundle') build_android(variant, versionCode) upload_to_play_store( track: track,