From 4fb457aee24315de18b6233d4ea09b841da104c1 Mon Sep 17 00:00:00 2001 From: Davide Date: Thu, 12 Dec 2024 16:56:16 +0100 Subject: [PATCH] Get optional device/platform from scripts --- ci/gen-screenshots.sh | 3 +++ ci/upload-metadata.sh | 9 +++++++-- ci/upload-screenshots.sh | 9 +++++++-- 3 files changed, 17 insertions(+), 4 deletions(-) diff --git a/ci/gen-screenshots.sh b/ci/gen-screenshots.sh index e3b4aa11..918dfdce 100755 --- a/ci/gen-screenshots.sh +++ b/ci/gen-screenshots.sh @@ -1,6 +1,9 @@ #!/bin/bash cwd=`dirname $0` devices=("iphone ipad mac appletv") +if [[ -n "$1" ]]; then + devices=("$1") +fi for device in $devices; do $cwd/../screenshots/export.sh $device $cwd/../screenshots/compose-device.sh $device diff --git a/ci/upload-metadata.sh b/ci/upload-metadata.sh index 8f226c5e..fb65176c 100755 --- a/ci/upload-metadata.sh +++ b/ci/upload-metadata.sh @@ -1,3 +1,8 @@ #!/bin/bash -platform=$1 -bundle exec fastlane --env secret,$platform asc_metadata +platforms=("iOS macOS tvOS") +if [[ -n "$1" ]]; then + platforms=("$1") +fi +for platform in $platforms; do + bundle exec fastlane --env secret,$platform asc_metadata +done diff --git a/ci/upload-screenshots.sh b/ci/upload-screenshots.sh index a6ddc02e..c40bf113 100755 --- a/ci/upload-screenshots.sh +++ b/ci/upload-screenshots.sh @@ -1,3 +1,8 @@ #!/bin/bash -platform=$1 -bundle exec fastlane --env secret,$platform asc_screenshots +platforms=("iOS macOS tvOS") +if [[ -n "$1" ]]; then + platforms=("$1") +fi +for platform in $platforms; do + bundle exec fastlane --env secret,$platform asc_screenshots +done