Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions scripts/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,14 @@

set -euo pipefail

if [ -d "/Applications/Xcode_16.1.app" ]; then
xcode_version="16.1"
iphone_version="16"
else
xcode_version="15.3"
iphone_version="15"
fi

# Set default parameters
if [[ -z "${SPM:-}" ]]; then
SPM=false
Expand All @@ -31,7 +39,7 @@ if [[ -z "${SPM:-}" ]]; then
fi
if [[ -z "${OS:-}" ]]; then
OS=iOS
DEVICE="iPhone 16"
DEVICE="iPhone ${iphone_version}"
echo "Defaulting to OS=$OS"
echo "Defaulting to DEVICE=$DEVICE"
fi
Expand Down Expand Up @@ -123,6 +131,6 @@ function xcb() {
}

# Run xcodebuild
sudo xcode-select -s /Applications/Xcode_16.1.app/Contents/Developer
sudo xcode-select -s "/Applications/Xcode_${xcode_version}.app/Contents/Developer"
xcb "${flags[@]}"
echo "$message"
Loading