diff --git a/.github/workflows/monthly.yml b/.github/workflows/monthly.yml index dc5dcb5..827627e 100644 --- a/.github/workflows/monthly.yml +++ b/.github/workflows/monthly.yml @@ -117,9 +117,13 @@ jobs: matrix: include: - macos_version: tahoe - xcode_version: "27" + xcode_version: "27.1" xcode_components: '"MetalToolchain"' latest: true + - macos_version: tahoe + xcode_version: "27" + xcode_components: '"MetalToolchain"' + latest: false - macos_version: tahoe xcode_version: "26.2" xcode_components: '"MetalToolchain"' @@ -165,9 +169,13 @@ jobs: xcode_components: "" latest: false - macos_version: golden-gate - xcode_version: "27" + xcode_version: "27.1" xcode_components: '"MetalToolchain"' latest: true + - macos_version: golden-gate + xcode_version: "27" + xcode_components: '"MetalToolchain"' + latest: false env: MACOS_VERSION: ${{ matrix.macos_version }} XCODE_COMPONENTS: ${{ matrix.xcode_components }} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 92356be..a39ddf9 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -101,7 +101,7 @@ jobs: matrix: include: - macos_version: golden-gate - xcode_versions: '"27"' + xcode_versions: '"27.1","27"' additional_ios_builds: "" additional_tvos_builds: "" xcode_components: '"MetalToolchain"' @@ -113,7 +113,7 @@ jobs: xcode_components: '"MetalToolchain"' disk_size: 380 - macos_version: tahoe - xcode_versions: '"27","26.6","27-beta-6","26.5","27-beta","26.4.1","26.3","26.2","26.1.1","26.0.1"' + xcode_versions: '"27.1","26.6","27-beta-6","27","26.5","27-beta","26.4.1","26.3","26.2","26.1.1","26.0.1"' additional_ios_builds: "18.6" additional_tvos_builds: "" xcode_components: '"MetalToolchain"' diff --git a/.github/workflows/template-validation.yml b/.github/workflows/template-validation.yml index 7500692..25d40e9 100644 --- a/.github/workflows/template-validation.yml +++ b/.github/workflows/template-validation.yml @@ -62,6 +62,7 @@ jobs: touch "$HOME/XcodesCache/Xcode_26.6.xip" touch "$HOME/XcodesCache/Xcode_27-beta-6.xip" touch "$HOME/XcodesCache/Xcode_27.xip" + touch "$HOME/XcodesCache/Xcode_27.1.xip" - name: Validate templates run: | @@ -81,7 +82,7 @@ jobs: validate templates/xcode.pkr.hcl \ -var macos_version=golden-gate \ - -var 'xcode_version=["27"]' \ + -var 'xcode_version=["27.1","27"]' \ -var 'xcode_components=["MetalToolchain"]' \ -var expected_runtimes_file=data/expected.golden-gate.runtimes.txt @@ -118,6 +119,11 @@ jobs: -var 'xcode_version=["27"]' \ -var 'xcode_components=["MetalToolchain"]' + validate templates/xcode.pkr.hcl \ + -var macos_version=tahoe \ + -var 'xcode_version=["27.1"]' \ + -var 'xcode_components=["MetalToolchain"]' + build-vanilla: name: Build Vanilla Image (${{ matrix.macos_version }}) needs: packer-validate @@ -264,7 +270,7 @@ jobs: matrix: include: - macos_version: tahoe - xcode_versions: '"27","26.6","27-beta-6","26.5","27-beta","26.4.1","26.3","26.2","26.1.1","26.0.1"' + xcode_versions: '"27.1","26.6","27-beta-6","27","26.5","27-beta","26.4.1","26.3","26.2","26.1.1","26.0.1"' additional_ios_builds: "18.6" additional_tvos_builds: "" xcode_components: '"MetalToolchain"' @@ -276,7 +282,7 @@ jobs: xcode_components: '"MetalToolchain"' disk_size: 380 - macos_version: golden-gate - xcode_versions: '"27"' + xcode_versions: '"27.1","27"' additional_ios_builds: "" additional_tvos_builds: "" xcode_components: '"MetalToolchain"' @@ -331,6 +337,7 @@ jobs: - name: Prepare Xcode archives if: steps.select.outputs.build == 'true' + timeout-minutes: 30 run: | set -euo pipefail @@ -341,6 +348,8 @@ jobs: fi mkdir -p "$HOME/XcodesCache" + download_dir="$(mktemp -d "$HOME/XcodesCache/.download.XXXXXX")" + trap 'rm -rf "$download_dir"' EXIT IFS=',' read -ra versions <<< "$XCODE_VERSIONS" for raw_version in "${versions[@]}"; do @@ -353,38 +362,22 @@ jobs: fi echo "Downloading Xcode $version" - if [[ -z "${FASTLANE_SESSION:-}" ]]; then - echo "::error::Missing $target and FASTLANE_SESSION is not configured. Pre-cache the Xcode archive on the runner or add Apple Developer auth secrets." + download_args=(download "$version" --directory "$download_dir") + if [[ -n "${FASTLANE_SESSION:-}" ]]; then + download_args+=(--use-fastlane-auth) + elif [[ -n "${FASTLANE_USER:-}" ]]; then + # An explicit user reads a cookie file instead of FASTLANE_SESSION. + download_args+=(--use-fastlane-auth --fastlane-user "$FASTLANE_USER") + fi + xcodes "${download_args[@]}" < /dev/null + + archives=("$download_dir"/*.xip) + if [[ ${#archives[@]} -ne 1 || ! -f "${archives[0]}" ]]; then + echo "::error::Expected exactly one downloaded Xcode archive for $version." exit 1 fi - download_args=(download "$version" --directory "$HOME/XcodesCache" --use-fastlane-auth) - if [[ -n "${FASTLANE_USER:-}" ]]; then - download_args+=(--fastlane-user "$FASTLANE_USER") - fi - xcodes "${download_args[@]}" - - candidate="" - case "$version" in - 27) - candidate="$HOME/XcodesCache/Xcode_27.0.xip" - ;; - 27-beta-6) - candidate="$HOME/XcodesCache/Xcode_27_beta_6.xip" - ;; - 27-beta) - candidate="$HOME/XcodesCache/Xcode_27_beta.xip" - ;; - *) - candidate="$(find "$HOME/XcodesCache" -maxdepth 1 -type f -name "Xcode_${version}*.xip" -print -quit)" - ;; - esac - - if [[ -n "$candidate" && -f "$candidate" && "$candidate" != "$target" ]]; then - mv "$candidate" "$target" - fi - - test -f "$target" + mv "${archives[0]}" "$target" done - name: Build runner image diff --git a/data/expected.golden-gate.runtimes.txt b/data/expected.golden-gate.runtimes.txt index 0743132..569be27 100644 --- a/data/expected.golden-gate.runtimes.txt +++ b/data/expected.golden-gate.runtimes.txt @@ -1,5 +1,6 @@ == Runtimes == iOS 27.0 (27.0 - 24A434) - com.apple.CoreSimulator.SimRuntime.iOS-27-0 +iOS 27.1 (27.1 - 24A94425) - com.apple.CoreSimulator.SimRuntime.iOS-27-1 tvOS 27.0 (27.0 - 24J360) - com.apple.CoreSimulator.SimRuntime.tvOS-27-0 watchOS 27.0 (27.0 - 24R362) - com.apple.CoreSimulator.SimRuntime.watchOS-27-0 visionOS 27.0 (27.0 - 24M362) - com.apple.CoreSimulator.SimRuntime.xrOS-27-0 diff --git a/data/expected.tahoe.runtimes.txt b/data/expected.tahoe.runtimes.txt index f775417..7c0ce9c 100644 --- a/data/expected.tahoe.runtimes.txt +++ b/data/expected.tahoe.runtimes.txt @@ -8,6 +8,7 @@ iOS 26.5 (26.5 - 23F77) - com.apple.CoreSimulator.SimRuntime.iOS-26-5 iOS 27.0 (27.0 - 24A5355p) - com.apple.CoreSimulator.SimRuntime.iOS-27-0 iOS 27.0 (27.0 - 24A5423a) - com.apple.CoreSimulator.SimRuntime.iOS-27-0 iOS 27.0 (27.0 - 24A434) - com.apple.CoreSimulator.SimRuntime.iOS-27-0 +iOS 27.1 (27.1 - 24A94425) - com.apple.CoreSimulator.SimRuntime.iOS-27-1 tvOS 26.5 (26.5 - 23L470) - com.apple.CoreSimulator.SimRuntime.tvOS-26-5 tvOS 27.0 (27.0 - 24J5356a) - com.apple.CoreSimulator.SimRuntime.tvOS-27-0 tvOS 27.0 (27.0 - 24J360) - com.apple.CoreSimulator.SimRuntime.tvOS-27-0