diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b7705ac..62e0bef 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -25,6 +25,9 @@ jobs: os: [ubuntu-latest, macos-latest, windows-latest] scala: [2.12.19] java: [temurin@8, temurin@11, temurin@17, temurin@21] + exclude: + - java: temurin@8 + os: macos-latest runs-on: ${{ matrix.os }} steps: - name: Ignore line ending differences in git @@ -77,6 +80,11 @@ jobs: java-version: 21 cache: sbt + - name: Install sbt + if: matrix.os == 'macos-latest' + shell: bash + run: brew install sbt + - name: Check that workflows are up to date shell: bash run: sbt '++ ${{ matrix.scala }}' githubWorkflowCheck diff --git a/build.sbt b/build.sbt index d347d54..551109b 100644 --- a/build.sbt +++ b/build.sbt @@ -83,3 +83,16 @@ ThisBuild / githubWorkflowJavaVersions := Seq( JavaSpec.temurin("17"), JavaSpec.temurin("21") ) + +ThisBuild / githubWorkflowBuildMatrixExclusions += MatrixExclude(Map("java" -> "temurin@8", "os" -> "macos-latest")) + +// GitHub Actions macOS 13+ runner images do not come with sbt preinstalled anymore +ThisBuild / githubWorkflowBuildPreamble ++= Seq( + WorkflowStep.Run( + commands = List( + "brew install sbt" + ), + cond = Some("matrix.os == 'macos-latest'"), + name = Some("Install sbt") + ) +)