Skip to content

Commit

Permalink
Set java version
Browse files Browse the repository at this point in the history
  • Loading branch information
gbastkowski committed Jun 24, 2024
1 parent 13aa4d2 commit 1fbb3b1
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 3 deletions.
20 changes: 18 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,22 @@ jobs:
matrix:
os: [ubuntu-latest]
scala: [3.4.2]
java: [temurin@8]
java: [temurin@8, temurin@21]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout current branch (full)
uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Setup Java (temurin@8)
if: matrix.java == 'temurin@8'
uses: actions/setup-java@v3
with:
distribution: temurin
java-version: 8
cache: sbt

- name: Setup Java (temurin@21)
if: matrix.java == 'temurin@21'
uses: actions/setup-java@v3
Expand Down Expand Up @@ -83,6 +91,14 @@ jobs:
java-version: 8
cache: sbt

- name: Setup Java (temurin@21)
if: matrix.java == 'temurin@21'
uses: actions/setup-java@v3
with:
distribution: temurin
java-version: 21
cache: sbt

- name: Download target directories (3.4.2)
uses: actions/download-artifact@v3
with:
Expand All @@ -108,7 +124,7 @@ jobs:
matrix:
os: [ubuntu-latest]
scala: [3.4.2]
java: [temurin@8]
java: [temurin@8, temurin@21]
runs-on: ${{ matrix.os }}
steps:
- name: Download target directories (3.4.2)
Expand Down
2 changes: 1 addition & 1 deletion build.sbt
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
ThisBuild / scalaVersion := Versions.scala3
ThisBuild / githubWorkflowJavaVersions += JavaSpec.temurin("21")

ThisBuild / githubWorkflowTargetTags ++= Seq("v*")
ThisBuild / githubWorkflowPublishTargetBranches += RefPredicate.StartsWith(Ref.Tag("v"))
Expand All @@ -9,7 +10,6 @@ ThisBuild / githubWorkflowPublish := Seq(
"PGP_SECRET" -> "${{ secrets.PGP_SECRET }}",
"SONATYPE_PASSWORD" -> "${{ secrets.SONATYPE_PASSWORD }}",
"SONATYPE_USERNAME" -> "${{ secrets.SONATYPE_USERNAME }}")))

ThisBuild / githubWorkflowUseSbtThinClient := false
ThisBuild / githubWorkflowAddedJobs += WorkflowJob(
id = "site",
Expand Down

0 comments on commit 1fbb3b1

Please sign in to comment.