Skip to content

Commit 151cba9

Browse files
author
Devon Stewart
committed
Overhauling github workflows to support publishing full compatibility artifacts
1 parent ff628fd commit 151cba9

File tree

3 files changed

+51
-78
lines changed

3 files changed

+51
-78
lines changed

.github/workflows/build.yml

+17-19
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,22 @@ on:
1212
- release/*
1313

1414
jobs:
15-
scala-2_12:
15+
scala:
1616
runs-on: ubuntu-latest
17+
strategy:
18+
matrix:
19+
java: [ '11' ]
20+
scala: [
21+
{ version: '2.12.13' },
22+
{ version: '2.12.12' },
23+
{ version: '2.12.11' },
24+
{ version: '2.12.10' },
25+
{ version: '2.13.4' },
26+
{ version: '2.13.3' },
27+
{ version: '2.13.2' },
28+
{ version: '2.13.1' },
29+
{ version: '2.13.0' }
30+
]
1731
steps:
1832
- name: checkout the repo
1933
uses: actions/checkout@v2
@@ -23,23 +37,7 @@ jobs:
2337
- name: Set up JDK
2438
uses: actions/setup-java@v1
2539
with:
26-
java-version: 11
40+
java-version: ${{ matrix.java }}
2741

2842
- name: run tests
29-
run: sbt ++2.12.10 test
30-
31-
scala-2_13:
32-
runs-on: ubuntu-latest
33-
steps:
34-
- name: checkout the repo
35-
uses: actions/checkout@v2
36-
with:
37-
fetch-depth: 0
38-
39-
- name: Set up JDK
40-
uses: actions/setup-java@v1
41-
with:
42-
java-version: 11
43-
44-
- name: run tests
45-
run: sbt ++2.13.3 test
43+
run: sbt ++${{ matrix.scala.version }} test

.github/workflows/pr.yml

+17-19
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,22 @@ on:
88
- '*.md'
99

1010
jobs:
11-
scala-2_12:
11+
scala:
1212
runs-on: ubuntu-latest
13+
strategy:
14+
matrix:
15+
java: [ '11' ]
16+
scala: [
17+
{ version: '2.12.13' },
18+
{ version: '2.12.12' },
19+
{ version: '2.12.11' },
20+
{ version: '2.12.10' },
21+
{ version: '2.13.4' },
22+
{ version: '2.13.3' },
23+
{ version: '2.13.2' },
24+
{ version: '2.13.1' },
25+
{ version: '2.13.0' }
26+
]
1327
steps:
1428
- name: checkout the repo
1529
uses: actions/checkout@v2
@@ -19,23 +33,7 @@ jobs:
1933
- name: Set up JDK
2034
uses: actions/setup-java@v1
2135
with:
22-
java-version: 11
36+
java-version: ${{ matrix.java.version }}
2337

2438
- name: run tests
25-
run: sbt ++2.12.10 test
26-
27-
scala-2_13:
28-
runs-on: ubuntu-latest
29-
steps:
30-
- name: checkout the repo
31-
uses: actions/checkout@v2
32-
with:
33-
fetch-depth: 0
34-
35-
- name: Set up JDK
36-
uses: actions/setup-java@v1
37-
with:
38-
java-version: 11
39-
40-
- name: run tests
41-
run: sbt ++2.13.3 test
39+
run: sbt ++${{ matrix.scala.version }} test

.github/workflows/release.yml

+17-40
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,22 @@ on:
1111
required: true
1212

1313
jobs:
14-
scala-2_12:
14+
scala:
1515
runs-on: ubuntu-latest
16+
strategy:
17+
matrix:
18+
java: [ '11' ]
19+
scala: [
20+
{ version: '2.12.13' },
21+
{ version: '2.12.12' },
22+
{ version: '2.12.11' },
23+
{ version: '2.12.10' },
24+
{ version: '2.13.4' },
25+
{ version: '2.13.3' },
26+
{ version: '2.13.2' },
27+
{ version: '2.13.1' },
28+
{ version: '2.13.0' }
29+
]
1630
steps:
1731
- name: checkout the repo
1832
uses: actions/checkout@v2
@@ -22,7 +36,7 @@ jobs:
2236
- name: Set up JDK
2337
uses: actions/setup-java@v1
2438
with:
25-
java-version: 11
39+
java-version: ${{ matrix.java }}
2640

2741
- name: Import GPG key
2842
id: import_gpg
@@ -39,45 +53,8 @@ jobs:
3953
echo "email: ${{ steps.import_gpg.outputs.email }}"
4054
4155
- name: publish release
42-
run: sbt ++2.12.10 publishSigned
56+
run: sbt ++${{ matrix.scala.version }} publishSigned
4357
env:
4458
RELEASE_VERSION: ${{ github.event.inputs.version }}
4559
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
4660
OSSRH_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
47-
48-
scala-2_13:
49-
runs-on: ubuntu-latest
50-
steps:
51-
- name: checkout the repo
52-
uses: actions/checkout@v2
53-
with:
54-
fetch-depth: 0
55-
56-
- name: Set up JDK
57-
uses: actions/setup-java@v1
58-
with:
59-
java-version: 11
60-
61-
- name: Import GPG key
62-
id: import_gpg
63-
uses: crazy-max/ghaction-import-gpg@v3
64-
with:
65-
gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }}
66-
passphrase: ${{ secrets.PGP_PASSPHRASE }}
67-
68-
- name: GPG user IDs
69-
run: |
70-
echo "fingerprint: ${{ steps.import_gpg.outputs.fingerprint }}"
71-
echo "keyid: ${{ steps.import_gpg.outputs.keyid }}"
72-
echo "name: ${{ steps.import_gpg.outputs.name }}"
73-
echo "email: ${{ steps.import_gpg.outputs.email }}"
74-
75-
- name: run tests
76-
run: sbt ++2.13.3 test
77-
78-
- name: publish release
79-
run: sbt ++2.13.3 publishSigned
80-
env:
81-
RELEASE_VERSION: ${{ github.event.inputs.version }}
82-
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
83-
OSSRH_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}

0 commit comments

Comments
 (0)