From 296e4d5697a92dcf5c28ceb6af7db0661be84cda Mon Sep 17 00:00:00 2001 From: Walid Kayhal <3347810+waliid@users.noreply.github.com> Date: Wed, 27 Nov 2024 11:22:08 +0100 Subject: [PATCH] Split configurations --- .github/workflows/pull-request.yml | 4 +++- Makefile | 20 ++++++++++++++------ fastlane/Fastfile | 28 +++++++++++++++++++++------- 3 files changed, 38 insertions(+), 14 deletions(-) diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index c4b1f979..e072f046 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -43,6 +43,7 @@ jobs: strategy: matrix: platform: [ios, tvos] + configuration: [nightly, release] steps: - name: Checkout code uses: actions/checkout@v4 @@ -61,4 +62,5 @@ jobs: ${{ secrets.APPLE_ACCOUNT_INFO_B64 }} - name: Archive the demo - run: make archive-demo-${{ matrix.platform }} + run: | + make archive-demo-${{ matrix.configuration }}-${{ matrix.platform }} diff --git a/Makefile b/Makefile index ad12fa6f..b86713ce 100644 --- a/Makefile +++ b/Makefile @@ -20,13 +20,21 @@ install-bundler: fastlane: install-pkgx install-bundler @pkgx bundle exec fastlane -.PHONY: archive-demo-ios -archive-demo-ios: install-pkgx install-bundler - @pkgx bundle exec fastlane archive_demo_ios +.PHONY: archive-demo-nightly-ios +archive-demo-nightly-ios: install-pkgx install-bundler + @pkgx bundle exec fastlane archive_demo_nightly_ios -.PHONY: archive-demo-tvos -archive-demo-tvos: install-pkgx install-bundler - @pkgx bundle exec fastlane archive_demo_tvos +.PHONY: archive-demo-nightly-tvos +archive-demo-nightly-tvos: install-pkgx install-bundler + @pkgx bundle exec fastlane archive_demo_nightly_tvos + +.PHONY: archive-demo-release-ios +archive-demo-release-ios: install-pkgx install-bundler + @pkgx bundle exec fastlane archive_demo_release_ios + +.PHONY: archive-demo-release-tvos +archive-demo-release-tvos: install-pkgx install-bundler + @pkgx bundle exec fastlane archive_demo_release_tvos .PHONY: deliver-demo-nightly-ios deliver-demo-nightly-ios: install-pkgx install-bundler diff --git a/fastlane/Fastfile b/fastlane/Fastfile index 34fe358a..d6e9d1b4 100644 --- a/fastlane/Fastfile +++ b/fastlane/Fastfile @@ -164,9 +164,13 @@ rescue StandardError => e UI.important('TestFlight external delivery was skipped because a build is already in review') end -def archive_demo(platform_id) +def archive_demo_nightly(platform_id) ensure_configuration_availability build_and_sign_app(platform_id, :nightly) +end + +def archive_demo_release(platform_id) + ensure_configuration_availability build_and_sign_app(platform_id, :release) end @@ -223,14 +227,24 @@ platform :ios do reset_git_repo(skip_clean: true) end - desc 'Archive the iOS demo app' - lane :archive_demo_ios do - archive_demo(:ios) + desc 'Archive the iOS nightly demo app' + lane :archive_demo_nightly_ios do + archive_demo_nightly(:ios) + end + + desc 'Archive the iOS release demo app' + lane :archive_demo_release_ios do + archive_demo_release(:ios) + end + + desc 'Archive the tvOS nightly demo app' + lane :archive_demo_nightly_tvos do + archive_demo_nightly(:tvos) end - desc 'Archive the tvOS demo app' - lane :archive_demo_tvos do - archive_demo(:tvos) + desc 'Archive the tvOS release demo app' + lane :archive_demo_release_tvos do + archive_demo_release(:tvos) end desc 'Deliver an iOS demo app nightly build'