diff --git a/fastlane/Deliverfile b/fastlane/Deliverfile deleted file mode 100644 index a27802c01..000000000 --- a/fastlane/Deliverfile +++ /dev/null @@ -1,34 +0,0 @@ -# The Deliverfile allows you to store various App Store Connect metadata -# For more information, check out the docs -# https://docs.fastlane.tools/actions/deliver/ - -######################################## -# App Metadata -######################################## - -# This folder has to include one folder for each language -screenshots_path "./screenshots/" -app_identifier "com.codality.NotationalFlow" - -# Make sure to update these keys for a new version -app_version "4.48" - -privacy_url({ - 'default' => 'https://simplenote.com/privacy/', -}) - -copyright('2021 Automattic') - -skip_binary_upload true -overwrite_screenshots true -phased_release true - -# We are using the API key to upload the metadata to ASC via Deliver, but, as -# the tool reports: -# -# > [!] Precheck cannot check In-app purchases with the App Store Connect API -# > Key (yet). Exclude In-app purchases from precheck, disable the precheck step -# > in your build step, or use Apple ID login -# -# Simplenote iOS doesn't use IAPs, for the moment, so we can safely skip them. -precheck_include_in_app_purchases false diff --git a/fastlane/Fastfile b/fastlane/Fastfile index 86500af20..68d4b9f65 100644 --- a/fastlane/Fastfile +++ b/fastlane/Fastfile @@ -89,7 +89,7 @@ end lane :code_freeze do | options | old_version = ios_codefreeze_prechecks(options) - ios_bump_version_release() + ios_bump_version_release(skip_deliver: true) new_version = ios_get_app_version() extract_release_notes_for_version(version: new_version, release_notes_file_path: File.join(PROJECT_ROOT_FOLDER, 'RELEASE-NOTES.txt'), @@ -437,7 +437,7 @@ end testflight( skip_waiting_for_build_processing: true, - api_key_path: File.join(Dir.home, '.configure', 'simplenote-ios', 'secrets', 'app_store_connect_fastlane_api_key.json') + api_key_path: APP_STORE_CONNECT_KEY_PATH ) sh("rm ../Simplenote.ipa") @@ -468,6 +468,31 @@ end end end + # Upload the localized metadata (from `fastlane/metadata/`) to App Store Connect + # + # @option [Boolean] with_screenshots (default: false) If true, will also upload the latest screenshot files to ASC + # + desc 'Upload the localized metadata to App Store Connect, optionally including screenshots.' + lane :update_metadata_on_app_store_connect do |options| + # Skip screenshots by default. The naming is "with" to make it clear that + # callers need to opt-in to adding screenshots. The naming of the deliver + # (upload_to_app_store) parameter, on the other hand, uses the skip verb. + with_screenshots = options.fetch(:with_screenshots, false) + skip_screenshots = !with_screenshots + + upload_to_app_store( + app_identifier: APP_STORE_BUNDLE_IDENTIFIER, + app_version: ios_get_app_version, + skip_binary_upload: true, + screenshots_path: promo_screenshots_directory, + skip_screenshots: skip_screenshots, + overwrite_screenshots: true, # won't have effect if `skip_screenshots` is true + phased_release: true, + precheck_include_in_app_purchases: false, + api_key_path: APP_STORE_CONNECT_KEY_PATH + ) + end + ##################################################################################### # trigger_beta_build # ----------------------------------------------------------------------------------- @@ -886,38 +911,6 @@ end appstore_code_signing end - lane :upload_screenshots do |options| - # This uses the following env vars from the user env: - # DELIVER_USER - # DELIVER_APP_IDENTIFIER - # FASTLANE_PASSWORD - # - # and from the project env: - # FASTLANE_ITC_TEAM_ID - upload_to_app_store( - edit_live: false, - use_live_version: false, - screenshots_path: promo_screenshots_directory, - skip_binary_upload: true, - skip_metadata: true, - skip_app_version_update: true, - - # Prechecks - run_precheck_before_submit: false, - precheck_include_in_app_purchases: false, - - # Delete all the previous screenshots on ASC - overwrite_screenshots: true, - # Set this to true to skip the interactive confirmation of the - # screenshots that will be uploaded. Please, though, don't do it, unless - # you disable the overwrite option above. If we loose the screenshot that - # are on ASC, we might not be able to recover them, unless we checkout - # whichever version made them and generate them again. - force: false, - submit_for_review: false - ) - end - ######################################################################## # Fastlane match code signing ######################################################################## diff --git a/fastlane/metadata/copyright.txt b/fastlane/metadata/copyright.txt new file mode 100644 index 000000000..c3ba849d7 --- /dev/null +++ b/fastlane/metadata/copyright.txt @@ -0,0 +1 @@ +2023 Automattic diff --git a/fastlane/metadata/default/privacy_url.txt b/fastlane/metadata/default/privacy_url.txt new file mode 100644 index 000000000..6e2284afd --- /dev/null +++ b/fastlane/metadata/default/privacy_url.txt @@ -0,0 +1 @@ +https://simplenote.com/privacy/