Skip to content

Commit efb956f

Browse files
authored
Merge pull request #395 from gnieh/updates
Bulk update dependencies
2 parents f6f2c5b + 9ee1504 commit efb956f

File tree

6 files changed

+135
-122
lines changed

6 files changed

+135
-122
lines changed

.github/workflows/ci.yml

Lines changed: 110 additions & 97 deletions
Original file line numberDiff line numberDiff line change
@@ -15,90 +15,76 @@ on:
1515
tags: [v*]
1616

1717
env:
18-
PGP_PASSPHRASE: ${{ secrets.PGP_PASSPHRASE }}
19-
SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }}
20-
SONATYPE_CREDENTIAL_HOST: ${{ secrets.SONATYPE_CREDENTIAL_HOST }}
21-
SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }}
22-
PGP_SECRET: ${{ secrets.PGP_SECRET }}
2318
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2419

20+
21+
concurrency:
22+
group: ${{ github.workflow }} @ ${{ github.ref }}
23+
cancel-in-progress: true
24+
2525
jobs:
2626
build:
2727
name: Build and Test
2828
strategy:
2929
matrix:
3030
os: [ubuntu-latest]
31-
scala: [2.12.18, 2.13.10, 3.2.2]
32-
java: [temurin@8]
33-
project: [rootJS, rootJVM, rootNative]
31+
scala: [2.12, 2.13, 3]
32+
java: [temurin@11]
33+
project: [diffsonJVM, diffsonJS, diffsonNative]
3434
runs-on: ${{ matrix.os }}
35+
timeout-minutes: 60
3536
steps:
3637
- name: Checkout current branch (full)
37-
uses: actions/checkout@v3
38+
uses: actions/checkout@v4
3839
with:
3940
fetch-depth: 0
4041

41-
- name: Download Java (temurin@8)
42-
id: download-java-temurin-8
43-
if: matrix.java == 'temurin@8'
44-
uses: typelevel/download-java@v2
42+
- name: Setup Java (temurin@11)
43+
id: setup-java-temurin-11
44+
if: matrix.java == 'temurin@11'
45+
uses: actions/setup-java@v4
4546
with:
4647
distribution: temurin
47-
java-version: 8
48-
49-
- name: Setup Java (temurin@8)
50-
if: matrix.java == 'temurin@8'
51-
uses: actions/setup-java@v3
52-
with:
53-
distribution: jdkfile
54-
java-version: 8
55-
jdkFile: ${{ steps.download-java-temurin-8.outputs.jdkFile }}
48+
java-version: 11
49+
cache: sbt
5650

57-
- name: Cache sbt
58-
uses: actions/cache@v3
59-
with:
60-
path: |
61-
~/.sbt
62-
~/.ivy2/cache
63-
~/.coursier/cache/v1
64-
~/.cache/coursier/v1
65-
~/AppData/Local/Coursier/Cache/v1
66-
~/Library/Caches/Coursier/v1
67-
key: ${{ runner.os }}-sbt-cache-v2-${{ hashFiles('**/*.sbt') }}-${{ hashFiles('project/build.properties') }}
51+
- name: sbt update
52+
if: matrix.java == 'temurin@11' && steps.setup-java-temurin-11.outputs.cache-hit == 'false'
53+
run: sbt +update
6854

6955
- name: Check that workflows are up to date
7056
run: sbt githubWorkflowCheck
7157

7258
- name: Check headers and formatting
73-
if: matrix.java == 'temurin@8' && matrix.os == 'ubuntu-latest'
59+
if: matrix.java == 'temurin@11' && matrix.os == 'ubuntu-latest'
7460
run: sbt 'project ${{ matrix.project }}' '++ ${{ matrix.scala }}' headerCheckAll scalafmtCheckAll 'project /' scalafmtSbtCheck
7561

7662
- name: scalaJSLink
77-
if: matrix.project == 'rootJS'
63+
if: matrix.project == 'diffsonJS'
7864
run: sbt 'project ${{ matrix.project }}' '++ ${{ matrix.scala }}' Test/scalaJSLinkerResult
7965

8066
- name: nativeLink
81-
if: matrix.project == 'rootNative'
67+
if: matrix.project == 'diffsonNative'
8268
run: sbt 'project ${{ matrix.project }}' '++ ${{ matrix.scala }}' Test/nativeLink
8369

8470
- name: Test
8571
run: sbt 'project ${{ matrix.project }}' '++ ${{ matrix.scala }}' test
8672

8773
- name: Check binary compatibility
88-
if: matrix.java == 'temurin@8' && matrix.os == 'ubuntu-latest'
74+
if: matrix.java == 'temurin@11' && matrix.os == 'ubuntu-latest'
8975
run: sbt 'project ${{ matrix.project }}' '++ ${{ matrix.scala }}' mimaReportBinaryIssues
9076

9177
- name: Generate API documentation
92-
if: matrix.java == 'temurin@8' && matrix.os == 'ubuntu-latest'
78+
if: matrix.java == 'temurin@11' && matrix.os == 'ubuntu-latest'
9379
run: sbt 'project ${{ matrix.project }}' '++ ${{ matrix.scala }}' doc
9480

9581
- name: Make target directories
9682
if: github.event_name != 'pull_request' && (startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/main')
97-
run: mkdir -p circe/jvm/target testkit/native/target target testkit/js/target .js/target core/.native/target playJson/jvm/target benchmarks/.jvm/target sprayJson/target core/.js/target circe/js/target core/.jvm/target .jvm/target .native/target circe/native/target playJson/js/target testkit/jvm/target project/target
83+
run: mkdir -p circe/jvm/target playJson/native/target testkit/native/target testkit/js/target core/.native/target playJson/jvm/target core/.js/target circe/js/target core/.jvm/target circe/native/target playJson/js/target testkit/jvm/target sprayJson/.jvm/target project/target
9884

9985
- name: Compress target directories
10086
if: github.event_name != 'pull_request' && (startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/main')
101-
run: tar cf targets.tar circe/jvm/target testkit/native/target target testkit/js/target .js/target core/.native/target playJson/jvm/target benchmarks/.jvm/target sprayJson/target core/.js/target circe/js/target core/.jvm/target .jvm/target .native/target circe/native/target playJson/js/target testkit/jvm/target project/target
87+
run: tar cf targets.tar circe/jvm/target playJson/native/target testkit/native/target testkit/js/target core/.native/target playJson/jvm/target core/.js/target circe/js/target core/.jvm/target circe/native/target playJson/js/target testkit/jvm/target sprayJson/.jvm/target project/target
10288

10389
- name: Upload target directories
10490
if: github.event_name != 'pull_request' && (startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/main')
@@ -114,143 +100,170 @@ jobs:
114100
strategy:
115101
matrix:
116102
os: [ubuntu-latest]
117-
scala: [2.13.10]
118-
java: [temurin@8]
103+
java: [temurin@11]
119104
runs-on: ${{ matrix.os }}
120105
steps:
121106
- name: Checkout current branch (full)
122-
uses: actions/checkout@v3
107+
uses: actions/checkout@v4
123108
with:
124109
fetch-depth: 0
125110

126-
- name: Download Java (temurin@8)
127-
id: download-java-temurin-8
128-
if: matrix.java == 'temurin@8'
129-
uses: typelevel/download-java@v2
111+
- name: Setup Java (temurin@11)
112+
id: setup-java-temurin-11
113+
if: matrix.java == 'temurin@11'
114+
uses: actions/setup-java@v4
130115
with:
131116
distribution: temurin
132-
java-version: 8
117+
java-version: 11
118+
cache: sbt
133119

134-
- name: Setup Java (temurin@8)
135-
if: matrix.java == 'temurin@8'
136-
uses: actions/setup-java@v3
137-
with:
138-
distribution: jdkfile
139-
java-version: 8
140-
jdkFile: ${{ steps.download-java-temurin-8.outputs.jdkFile }}
120+
- name: sbt update
121+
if: matrix.java == 'temurin@11' && steps.setup-java-temurin-11.outputs.cache-hit == 'false'
122+
run: sbt +update
141123

142-
- name: Cache sbt
143-
uses: actions/cache@v3
144-
with:
145-
path: |
146-
~/.sbt
147-
~/.ivy2/cache
148-
~/.coursier/cache/v1
149-
~/.cache/coursier/v1
150-
~/AppData/Local/Coursier/Cache/v1
151-
~/Library/Caches/Coursier/v1
152-
key: ${{ runner.os }}-sbt-cache-v2-${{ hashFiles('**/*.sbt') }}-${{ hashFiles('project/build.properties') }}
153-
154-
- name: Download target directories (2.12.18, rootJS)
124+
- name: Download target directories (2.12, diffsonJVM)
155125
uses: actions/download-artifact@v3
156126
with:
157-
name: target-${{ matrix.os }}-${{ matrix.java }}-2.12.18-rootJS
127+
name: target-${{ matrix.os }}-${{ matrix.java }}-2.12-diffsonJVM
158128

159-
- name: Inflate target directories (2.12.18, rootJS)
129+
- name: Inflate target directories (2.12, diffsonJVM)
160130
run: |
161131
tar xf targets.tar
162132
rm targets.tar
163133
164-
- name: Download target directories (2.12.18, rootJVM)
134+
- name: Download target directories (2.12, diffsonJS)
165135
uses: actions/download-artifact@v3
166136
with:
167-
name: target-${{ matrix.os }}-${{ matrix.java }}-2.12.18-rootJVM
137+
name: target-${{ matrix.os }}-${{ matrix.java }}-2.12-diffsonJS
168138

169-
- name: Inflate target directories (2.12.18, rootJVM)
139+
- name: Inflate target directories (2.12, diffsonJS)
170140
run: |
171141
tar xf targets.tar
172142
rm targets.tar
173143
174-
- name: Download target directories (2.12.18, rootNative)
144+
- name: Download target directories (2.12, diffsonNative)
175145
uses: actions/download-artifact@v3
176146
with:
177-
name: target-${{ matrix.os }}-${{ matrix.java }}-2.12.18-rootNative
147+
name: target-${{ matrix.os }}-${{ matrix.java }}-2.12-diffsonNative
178148

179-
- name: Inflate target directories (2.12.18, rootNative)
149+
- name: Inflate target directories (2.12, diffsonNative)
180150
run: |
181151
tar xf targets.tar
182152
rm targets.tar
183153
184-
- name: Download target directories (2.13.10, rootJS)
154+
- name: Download target directories (2.13, diffsonJVM)
185155
uses: actions/download-artifact@v3
186156
with:
187-
name: target-${{ matrix.os }}-${{ matrix.java }}-2.13.10-rootJS
157+
name: target-${{ matrix.os }}-${{ matrix.java }}-2.13-diffsonJVM
188158

189-
- name: Inflate target directories (2.13.10, rootJS)
159+
- name: Inflate target directories (2.13, diffsonJVM)
190160
run: |
191161
tar xf targets.tar
192162
rm targets.tar
193163
194-
- name: Download target directories (2.13.10, rootJVM)
164+
- name: Download target directories (2.13, diffsonJS)
195165
uses: actions/download-artifact@v3
196166
with:
197-
name: target-${{ matrix.os }}-${{ matrix.java }}-2.13.10-rootJVM
167+
name: target-${{ matrix.os }}-${{ matrix.java }}-2.13-diffsonJS
198168

199-
- name: Inflate target directories (2.13.10, rootJVM)
169+
- name: Inflate target directories (2.13, diffsonJS)
200170
run: |
201171
tar xf targets.tar
202172
rm targets.tar
203173
204-
- name: Download target directories (2.13.10, rootNative)
174+
- name: Download target directories (2.13, diffsonNative)
205175
uses: actions/download-artifact@v3
206176
with:
207-
name: target-${{ matrix.os }}-${{ matrix.java }}-2.13.10-rootNative
177+
name: target-${{ matrix.os }}-${{ matrix.java }}-2.13-diffsonNative
208178

209-
- name: Inflate target directories (2.13.10, rootNative)
179+
- name: Inflate target directories (2.13, diffsonNative)
210180
run: |
211181
tar xf targets.tar
212182
rm targets.tar
213183
214-
- name: Download target directories (3.2.2, rootJS)
184+
- name: Download target directories (3, diffsonJVM)
215185
uses: actions/download-artifact@v3
216186
with:
217-
name: target-${{ matrix.os }}-${{ matrix.java }}-3.2.2-rootJS
187+
name: target-${{ matrix.os }}-${{ matrix.java }}-3-diffsonJVM
218188

219-
- name: Inflate target directories (3.2.2, rootJS)
189+
- name: Inflate target directories (3, diffsonJVM)
220190
run: |
221191
tar xf targets.tar
222192
rm targets.tar
223193
224-
- name: Download target directories (3.2.2, rootJVM)
194+
- name: Download target directories (3, diffsonJS)
225195
uses: actions/download-artifact@v3
226196
with:
227-
name: target-${{ matrix.os }}-${{ matrix.java }}-3.2.2-rootJVM
197+
name: target-${{ matrix.os }}-${{ matrix.java }}-3-diffsonJS
228198

229-
- name: Inflate target directories (3.2.2, rootJVM)
199+
- name: Inflate target directories (3, diffsonJS)
230200
run: |
231201
tar xf targets.tar
232202
rm targets.tar
233203
234-
- name: Download target directories (3.2.2, rootNative)
204+
- name: Download target directories (3, diffsonNative)
235205
uses: actions/download-artifact@v3
236206
with:
237-
name: target-${{ matrix.os }}-${{ matrix.java }}-3.2.2-rootNative
207+
name: target-${{ matrix.os }}-${{ matrix.java }}-3-diffsonNative
238208

239-
- name: Inflate target directories (3.2.2, rootNative)
209+
- name: Inflate target directories (3, diffsonNative)
240210
run: |
241211
tar xf targets.tar
242212
rm targets.tar
243213
244214
- name: Import signing key
245215
if: env.PGP_SECRET != '' && env.PGP_PASSPHRASE == ''
246-
run: echo $PGP_SECRET | base64 -di | gpg --import
216+
env:
217+
PGP_SECRET: ${{ secrets.PGP_SECRET }}
218+
PGP_PASSPHRASE: ${{ secrets.PGP_PASSPHRASE }}
219+
run: echo $PGP_SECRET | base64 -d -i - | gpg --import
247220

248221
- name: Import signing key and strip passphrase
249222
if: env.PGP_SECRET != '' && env.PGP_PASSPHRASE != ''
223+
env:
224+
PGP_SECRET: ${{ secrets.PGP_SECRET }}
225+
PGP_PASSPHRASE: ${{ secrets.PGP_PASSPHRASE }}
250226
run: |
251-
echo "$PGP_SECRET" | base64 -di > /tmp/signing-key.gpg
227+
echo "$PGP_SECRET" | base64 -d -i - > /tmp/signing-key.gpg
252228
echo "$PGP_PASSPHRASE" | gpg --pinentry-mode loopback --passphrase-fd 0 --import /tmp/signing-key.gpg
253229
(echo "$PGP_PASSPHRASE"; echo; echo) | gpg --command-fd 0 --pinentry-mode loopback --change-passphrase $(gpg --list-secret-keys --with-colons 2> /dev/null | grep '^sec:' | cut --delimiter ':' --fields 5 | tail -n 1)
254230
255231
- name: Publish
256-
run: sbt '++ ${{ matrix.scala }}' tlCiRelease
232+
env:
233+
SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }}
234+
SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }}
235+
SONATYPE_CREDENTIAL_HOST: ${{ secrets.SONATYPE_CREDENTIAL_HOST }}
236+
run: sbt tlCiRelease
237+
238+
dependency-submission:
239+
name: Submit Dependencies
240+
if: github.event_name != 'pull_request'
241+
strategy:
242+
matrix:
243+
os: [ubuntu-latest]
244+
java: [temurin@11]
245+
runs-on: ${{ matrix.os }}
246+
steps:
247+
- name: Checkout current branch (full)
248+
uses: actions/checkout@v4
249+
with:
250+
fetch-depth: 0
251+
252+
- name: Setup Java (temurin@11)
253+
id: setup-java-temurin-11
254+
if: matrix.java == 'temurin@11'
255+
uses: actions/setup-java@v4
256+
with:
257+
distribution: temurin
258+
java-version: 11
259+
cache: sbt
260+
261+
- name: sbt update
262+
if: matrix.java == 'temurin@11' && steps.setup-java-temurin-11.outputs.cache-hit == 'false'
263+
run: sbt +update
264+
265+
- name: Submit Dependencies
266+
uses: scalacenter/sbt-dependency-submission@v2
267+
with:
268+
modules-ignore: diffsonjvm_2.12 diffsonjvm_2.13 diffsonjvm_3 diffsonjs_2.12 diffsonjs_2.13 diffsonjs_3 diffson-benchmarks_2.12 diffson-benchmarks_2.13 diffson-benchmarks_3 diffsonnative_2.12 diffsonnative_2.13 diffsonnative_3
269+
configs-ignore: test scala-tool scala-doc-tool test-internal

0 commit comments

Comments
 (0)