Skip to content

Commit fd4670f

Browse files
authored
Merge pull request #328 from armanbilge/issue/327
Only download artifacts for primary OS/JDK
2 parents 42eec29 + 23e75b9 commit fd4670f

File tree

4 files changed

+54
-3
lines changed

4 files changed

+54
-3
lines changed

.github/workflows/ci.yml

Lines changed: 49 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
matrix:
3030
os: [ubuntu-latest]
3131
scala: [2.12.16]
32-
java: [temurin@8]
32+
java: [temurin@8, temurin@17]
3333
project: [rootJVM]
3434
runs-on: ${{ matrix.os }}
3535
steps:
@@ -54,6 +54,22 @@ jobs:
5454
java-version: 8
5555
jdkFile: ${{ steps.download-java-temurin-8.outputs.jdkFile }}
5656

57+
- name: Download Java (temurin@17)
58+
id: download-java-temurin-17
59+
if: matrix.java == 'temurin@17'
60+
uses: typelevel/download-java@v1
61+
with:
62+
distribution: temurin
63+
java-version: 17
64+
65+
- name: Setup Java (temurin@17)
66+
if: matrix.java == 'temurin@17'
67+
uses: actions/setup-java@v2
68+
with:
69+
distribution: jdkfile
70+
java-version: 17
71+
jdkFile: ${{ steps.download-java-temurin-17.outputs.jdkFile }}
72+
5773
- name: Cache sbt
5874
uses: actions/cache@v2
5975
with:
@@ -135,6 +151,22 @@ jobs:
135151
java-version: 8
136152
jdkFile: ${{ steps.download-java-temurin-8.outputs.jdkFile }}
137153

154+
- name: Download Java (temurin@17)
155+
id: download-java-temurin-17
156+
if: matrix.java == 'temurin@17'
157+
uses: typelevel/download-java@v1
158+
with:
159+
distribution: temurin
160+
java-version: 17
161+
162+
- name: Setup Java (temurin@17)
163+
if: matrix.java == 'temurin@17'
164+
uses: actions/setup-java@v2
165+
with:
166+
distribution: jdkfile
167+
java-version: 17
168+
jdkFile: ${{ steps.download-java-temurin-17.outputs.jdkFile }}
169+
138170
- name: Cache sbt
139171
uses: actions/cache@v2
140172
with:
@@ -201,6 +233,22 @@ jobs:
201233
java-version: 8
202234
jdkFile: ${{ steps.download-java-temurin-8.outputs.jdkFile }}
203235

236+
- name: Download Java (temurin@17)
237+
id: download-java-temurin-17
238+
if: matrix.java == 'temurin@17'
239+
uses: typelevel/download-java@v1
240+
with:
241+
distribution: temurin
242+
java-version: 17
243+
244+
- name: Setup Java (temurin@17)
245+
if: matrix.java == 'temurin@17'
246+
uses: actions/setup-java@v2
247+
with:
248+
distribution: jdkfile
249+
java-version: 17
250+
jdkFile: ${{ steps.download-java-temurin-17.outputs.jdkFile }}
251+
204252
- name: Cache sbt
205253
uses: actions/cache@v2
206254
with:

.mergify.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ pull_request_rules:
1313
- body~=labels:.*early-semver-patch
1414
- body~=labels:.*early-semver-minor
1515
- status-success=Build and Test (ubuntu-latest, 2.12.16, temurin@8, rootJVM)
16+
- status-success=Build and Test (ubuntu-latest, 2.12.16, temurin@17, rootJVM)
1617
- '#approved-reviews-by>=1'
1718
actions:
1819
merge: {}

build.sbt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ ThisBuild / developers := List(
1111
tlGitHubDev("djspiewak", "Daniel Spiewak")
1212
)
1313

14+
ThisBuild / githubWorkflowJavaVersions += JavaSpec.temurin("17")
15+
1416
ThisBuild / mergifyStewardConfig ~= {
1517
_.map(_.copy(mergeMinors = true, author = "typelevel-steward[bot]"))
1618
}

github-actions/src/main/scala/org/typelevel/sbt/gha/GenerativePlugin.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -615,9 +615,9 @@ ${indent(jobs.map(compileJob(_, sbt)).mkString("\n\n"), 1)}
615615
}
616616

617617
val keys = "scala" :: additions.keys.toList.sorted
618-
val oses = githubWorkflowOSes.value.toList
618+
val oses = githubWorkflowOSes.value.toList.take(1)
619619
val scalas = githubWorkflowScalaVersions.value.toList
620-
val javas = githubWorkflowJavaVersions.value.toList
620+
val javas = githubWorkflowJavaVersions.value.toList.take(1)
621621
val exclusions = githubWorkflowBuildMatrixExclusions.value.toList
622622

623623
// we build the list of artifacts, by iterating over all combinations of keys

0 commit comments

Comments
 (0)