From 861a0b3570bc1a57a757e6ff302c49000b24a34b Mon Sep 17 00:00:00 2001 From: Remy Moll Date: Sat, 14 Dec 2024 18:41:11 +0100 Subject: [PATCH] keep using match --- frontend/.github/workflows/build_app_ios.yaml | 6 ++++ frontend/ios/fastlane/Fastfile | 31 +++++-------------- 2 files changed, 13 insertions(+), 24 deletions(-) diff --git a/frontend/.github/workflows/build_app_ios.yaml b/frontend/.github/workflows/build_app_ios.yaml index d0ac83d..1dbad5d 100644 --- a/frontend/.github/workflows/build_app_ios.yaml +++ b/frontend/.github/workflows/build_app_ios.yaml @@ -41,6 +41,12 @@ jobs: secret/release IOS_ASC_KEY_ID | IOS_ASC_KEY_ID ; secret/release IOS_ASC_ISSUER_ID | IOS_ASC_ISSUER_ID ; secret/release IOS_ASC_KEY_P8 | IOS_ASC_KEY_P8 ; + secret/release IOS_MATCH_REPO_SSH_KEY_BASE64 | IOS_MATCH_REPO_SSH_KEY_BASE64 ; + + - name: Setup SSH key for match git repo + run: echo "$MATCH_REPO_SSH_KEY" | base64 --decode > ~/.ssh/id_rsa && chmod 600 ~/.ssh/id_rsa + env: + MATCH_REPO_SSH_KEY: ${{ steps.load-secrets.outputs.IOS_MATCH_REPO_SSH_KEY_BASE64 }} - name: Install fastlane run: bundle install diff --git a/frontend/ios/fastlane/Fastfile b/frontend/ios/fastlane/Fastfile index 6d3d041..3c331bd 100644 --- a/frontend/ios/fastlane/Fastfile +++ b/frontend/ios/fastlane/Fastfile @@ -53,26 +53,15 @@ platform :ios do lane :deploy_testing do build_name = ENV["BUILD_NAME"] build_number = ENV["BUILD_NUMBER"] - - app_identifier = CredentialsManager::AppfileConfig.try_fetch_value(:app_identifier) load_asc_api_token - prepare_signing - profile_name = "App Provisioning Profile" # replace with the name of the profile to use for the build - output_name = "example-iOS" # specify the name of the .ipa file to generate - export_method = "app-store" # specify the export method - - # turn off automatic signing during build so correct code signing identity is guaranteed to be used - update_code_signing_settings( - use_automatic_signing: false, - targets: ["main-target"], # specify which targets to update code signing settings for - code_sign_identity: "Apple Distribution", # replace with name of code signing identity if different - bundle_identifier: app_identifier, - profile_name: profile_name, - build_configurations: ["Release"] # only toggle code signing settings for Release configurations + sync_code_signing( + api_key: api_key, + type: "testflight", + readonly: true, ) - + sh( "flutter", @@ -87,10 +76,6 @@ platform :ios do build_app( skip_build_archive: true, archive_path: "../build/ios/archive/Runner.xcarchive" - provisioningProfiles: { - app_identifier => profile_name - } - ) upload_to_testflight @@ -99,11 +84,11 @@ platform :ios do desc "Deploy a new version as a full release" lane :deploy_release do - build_name = ENV["BUILD_NAME"] build_number = ENV["BUILD_NUMBER"] + + load_asc_api_token - api_key = lane_context[SharedValues::APP_STORE_CONNECT_API_KEY] sync_code_signing( api_key: api_key, type: "appstore", @@ -136,5 +121,3 @@ platform :ios do # automatically release the app after review ) end - -