diff --git a/.github/workflows/__export-file-baseline-information.yml b/.github/workflows/__export-file-baseline-information.yml index 7ba7267648..ab15297942 100644 --- a/.github/workflows/__export-file-baseline-information.yml +++ b/.github/workflows/__export-file-baseline-information.yml @@ -43,7 +43,8 @@ jobs: with: version: ${{ matrix.version }} - uses: swift-actions/setup-swift@5cdaa9161ad1f55ae39a5ea1784ef96de72f95d9 - if: runner.os != 'Windows' && matrix.version == 'cached' + # Windows doesn't support Swift, and only macOS latest and nightly-latest support Swift 5.7.1. + if: "!(runner.os == 'macOS' && matrix.version != 'cached')" with: swift-version: '5.7' - uses: ./../action/init diff --git a/.github/workflows/__multi-language-autodetect.yml b/.github/workflows/__multi-language-autodetect.yml index 9d72fa6a5a..ab4b7eefd8 100644 --- a/.github/workflows/__multi-language-autodetect.yml +++ b/.github/workflows/__multi-language-autodetect.yml @@ -66,7 +66,8 @@ jobs: with: go-version: ^1.13.1 - uses: swift-actions/setup-swift@5cdaa9161ad1f55ae39a5ea1784ef96de72f95d9 - if: matrix.version == 'cached' + # Only macOS latest and nightly-latest support Swift 5.7.1 + if: runner.os == 'ubuntu' || matrix.version == 'cached' with: swift-version: '5.7' diff --git a/.github/workflows/__swift-autobuild.yml b/.github/workflows/__swift-autobuild.yml index a13078de98..2b3b72c03c 100644 --- a/.github/workflows/__swift-autobuild.yml +++ b/.github/workflows/__swift-autobuild.yml @@ -43,7 +43,8 @@ jobs: with: version: ${{ matrix.version }} - uses: swift-actions/setup-swift@5cdaa9161ad1f55ae39a5ea1784ef96de72f95d9 - if: matrix.version == 'cached' + # Only macOS latest and nightly-latest support Swift 5.7.1 + if: runner.os == 'ubuntu' || matrix.version == 'cached' with: swift-version: '5.7' - uses: ./../action/init diff --git a/.github/workflows/__swift-custom-build.yml b/.github/workflows/__swift-custom-build.yml index 5a89ed5751..68d55d04cc 100644 --- a/.github/workflows/__swift-custom-build.yml +++ b/.github/workflows/__swift-custom-build.yml @@ -49,7 +49,8 @@ jobs: with: version: ${{ matrix.version }} - uses: swift-actions/setup-swift@5cdaa9161ad1f55ae39a5ea1784ef96de72f95d9 - if: matrix.version == 'cached' + # Only macOS latest and nightly-latest support Swift 5.7.1 + if: runner.os == 'ubuntu' || matrix.version == 'cached' with: swift-version: '5.7' - uses: ./../action/init diff --git a/pr-checks/checks/export-file-baseline-information.yml b/pr-checks/checks/export-file-baseline-information.yml index 86d8ef8e6e..efb1cacfb4 100644 --- a/pr-checks/checks/export-file-baseline-information.yml +++ b/pr-checks/checks/export-file-baseline-information.yml @@ -3,7 +3,8 @@ description: "Tests that file baseline information is exported when the feature versions: ["nightly-latest"] steps: - uses: swift-actions/setup-swift@5cdaa9161ad1f55ae39a5ea1784ef96de72f95d9 - if: runner.os != 'Windows' && matrix.version == 'cached' + # Windows doesn't support Swift, and only macOS latest and nightly-latest support Swift 5.7.1. + if: "!(runner.os == 'macOS' && matrix.version != 'cached')" with: swift-version: "5.7" - uses: ./../action/init diff --git a/pr-checks/checks/multi-language-autodetect.yml b/pr-checks/checks/multi-language-autodetect.yml index db5a47c8b6..d10d5c33ff 100644 --- a/pr-checks/checks/multi-language-autodetect.yml +++ b/pr-checks/checks/multi-language-autodetect.yml @@ -5,7 +5,8 @@ env: CODEQL_ENABLE_EXPERIMENTAL_FEATURES_SWIFT: "true" # Remove when Swift is GA. steps: - uses: swift-actions/setup-swift@5cdaa9161ad1f55ae39a5ea1784ef96de72f95d9 - if: matrix.version == 'cached' + # Only macOS latest and nightly-latest support Swift 5.7.1 + if: runner.os == 'ubuntu' || matrix.version == 'cached' with: swift-version: "5.7" diff --git a/pr-checks/checks/swift-autobuild.yml b/pr-checks/checks/swift-autobuild.yml index 16dc25853b..e06851f505 100644 --- a/pr-checks/checks/swift-autobuild.yml +++ b/pr-checks/checks/swift-autobuild.yml @@ -7,7 +7,8 @@ env: CODEQL_ENABLE_EXPERIMENTAL_FEATURES_SWIFT: "true" steps: - uses: swift-actions/setup-swift@5cdaa9161ad1f55ae39a5ea1784ef96de72f95d9 - if: matrix.version == 'cached' + # Only macOS latest and nightly-latest support Swift 5.7.1 + if: runner.os == 'ubuntu' || matrix.version == 'cached' with: swift-version: "5.7" - uses: ./../action/init diff --git a/pr-checks/checks/swift-custom-build.yml b/pr-checks/checks/swift-custom-build.yml index 3dc0060c7e..ef3865f44b 100644 --- a/pr-checks/checks/swift-custom-build.yml +++ b/pr-checks/checks/swift-custom-build.yml @@ -7,7 +7,8 @@ env: DOTNET_GENERATE_ASPNET_CERTIFICATE: "false" steps: - uses: swift-actions/setup-swift@5cdaa9161ad1f55ae39a5ea1784ef96de72f95d9 - if: matrix.version == 'cached' + # Only macOS latest and nightly-latest support Swift 5.7.1 + if: runner.os == 'ubuntu' || matrix.version == 'cached' with: swift-version: "5.7" - uses: ./../action/init