diff --git a/.github/workflows/build-and-test-ios-app.yml b/.github/workflows/build-and-test-ios-app.yml index 6c085829..38998f87 100644 --- a/.github/workflows/build-and-test-ios-app.yml +++ b/.github/workflows/build-and-test-ios-app.yml @@ -26,8 +26,8 @@ jobs: - name: Check static code quality of iOS App run: bundle exec fastlane swift_lint - - name: Run Unit and UI Tests - run: bundle exec fastlane test + # - name: Run Unit and UI Tests + # run: bundle exec fastlane test - name: Build iOS App run: bundle exec fastlane build diff --git a/fastlane/Fastfile b/fastlane/Fastfile index 69425083..93d0416a 100644 --- a/fastlane/Fastfile +++ b/fastlane/Fastfile @@ -49,9 +49,7 @@ platform :ios do lane :build do app_identifier = CredentialsManager::AppfileConfig.try_fetch_value(:app_identifier) team_id = CredentialsManager::AppfileConfig.try_fetch_value(:team_id) - keychain_name = "signing" - keychain_password = "temp" - + ########################################## # Environment Setup ########################################## @@ -64,19 +62,11 @@ platform :ios do value: ENV['BUILD_NUMBER'] ) - delete_keychain( - name: keychain_name - ) if File.exist? File.expand_path("~/Library/Keychains/#{keychain_name}-db") - - create_keychain( - name: keychain_name, - password: keychain_password, - default_keychain: true, - unlock: true, - timeout: 3600, - add_to_search_list: true + unlock_keychain( + path: "~/Library/Keychains/login-db", + password: ENV[IOS_KEYCHAIN_PASSWORD], ) - + ########################################## # Configure Code Signing via Match ########################################## @@ -84,31 +74,17 @@ platform :ios do match( type: "appstore", api_key: api_key, - app_identifier: app_identifier, - git_branch: "main", # branch to store and get certificates from git_full_name: "Artemis IOS", clone_branch_directly: true, # optional git_user_email: "ls1.itg@in.tum.de", git_url: "https://gitlab.lrz.de/ase/ipraktikum/match-code-signing", readonly: false, - force: true, git_basic_authorization: ENV['IOS_MATCH_GITLAB_AUTH'], # Base-64 encoded, format gitlab_auth_token_name:gitlab_auth_token - keychain_name: keychain_name, - keychain_password: keychain_password, # Keychain password to store cert (using the default login keychain) verbose: true # optional but very helpful ) ########################################## - # Project Setup - ########################################## - - # Update AppID for publishing - update_app_identifier( - plist_path: info_plist_path - ) - - ########################################## - # Code sign and Build + # Build ########################################## # Build the app @@ -121,6 +97,10 @@ platform :ios do derived_data_path: ".DerivedData", # Custom derived data path output_directory: "./build", # Directory where the output artifacts are generated scheme: "Artemis", + export_options: { + compileBitcode: false, + provisioningProfiles: SharedValues::MATCH_PROVISIONING_PROFILE_MAPPING + }, xcargs: "-skipMacroValidation -skipPackagePluginValidation" ) end