Skip to content

Commit 9ec5535

Browse files
committed
just following a common practice we agreed upon a while ago
1 parent 2dfae38 commit 9ec5535

File tree

5 files changed

+42
-15
lines changed

5 files changed

+42
-15
lines changed

.github/workflows/build.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,16 @@ jobs:
3232
name: Scala ${{matrix.scala}}
3333
steps:
3434
- name: Checkout code
35-
uses: actions/checkout@v4
36-
- uses: coursier/cache-action@v6
35+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8
36+
with:
37+
persist-credentials: false
38+
39+
- uses: coursier/cache-action@bebeeb0e6f48ebad66d3783946588ecf43114433
40+
3741
- name: Setup Scala
38-
uses: olafurpg/setup-scala@v14
42+
uses: olafurpg/setup-scala@32ffa16635ff8f19cc21ea253a987f0fdf29844c
3943
with:
4044
java-version: "[email protected]"
45+
4146
- name: Build and run tests
4247
run: sbt ++${{matrix.scala}} test doc

.github/workflows/format_check.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,13 +26,16 @@ jobs:
2626
name: Scalafmt Check
2727
steps:
2828
- name: Checkout code
29-
uses: actions/checkout@v4
29+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8
3030
with:
31+
persist-credentials: false
3132
fetch-depth: 0
3233
ref: ${{ github.event.pull_request.head.ref }}
33-
- uses: coursier/cache-action@v6
34+
35+
- uses: coursier/cache-action@bebeeb0e6f48ebad66d3783946588ecf43114433
36+
3437
- name: Setup Scala
35-
uses: olafurpg/setup-scala@v14
38+
uses: olafurpg/setup-scala@32ffa16635ff8f19cc21ea253a987f0fdf29844c
3639
with:
3740
java-version: "[email protected]"
3841

.github/workflows/jacoco_check.yml

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,31 +37,39 @@ jobs:
3737
changed: 80.0
3838
steps:
3939
- name: Checkout code
40-
uses: actions/checkout@v4
41-
- uses: coursier/cache-action@v6
40+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8
41+
with:
42+
persist-credentials: false
43+
44+
- uses: coursier/cache-action@bebeeb0e6f48ebad66d3783946588ecf43114433
45+
4246
- name: Setup Scala
43-
uses: olafurpg/setup-scala@v14
47+
uses: olafurpg/setup-scala@32ffa16635ff8f19cc21ea253a987f0fdf29844c
4448
with:
4549
java-version: "[email protected]"
50+
4651
- name: Build and run tests
4752
run: sbt ++${{matrix.scala}} jacoco
53+
4854
- name: Add coverage to PR
4955
id: jacoco
50-
uses: madrapps/jacoco-report@v1.3
56+
uses: madrapps/jacoco-report@50d3aff4548aa991e6753342d9ba291084e63848
5157
with:
5258
paths: ${{ github.workspace }}/target/scala-${{ matrix.scalaShort }}/jacoco/report/jacoco.xml
5359
token: ${{ secrets.GITHUB_TOKEN }}
5460
min-coverage-overall: ${{ matrix.overall }}
5561
min-coverage-changed-files: ${{ matrix.changed }}
5662
title: JaCoCo code coverage report - scala ${{ matrix.scala }}
5763
update-comment: true
64+
5865
- name: Get the Coverage info
5966
run: |
6067
echo "Total coverage ${{ steps.jacoco.outputs.coverage-overall }}"
6168
echo "Changed Files coverage ${{ steps.jacoco.outputs.coverage-changed-files }}"
69+
6270
- name: Fail PR if changed files coverage is less than ${{ matrix.changed }}%
6371
if: ${{ steps.jacoco.outputs.coverage-changed-files < 80.0 }}
64-
uses: actions/github-script@v6
72+
uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd
6573
with:
6674
script: |
6775
core.setFailed('Changed files coverage is less than ${{ matrix.changed }}%!')

.github/workflows/licence_check.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,15 @@ jobs:
2727
runs-on: ubuntu-latest
2828
steps:
2929
- name: Checkout code
30-
uses: actions/checkout@v2
30+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8
31+
with:
32+
persist-credentials: false
33+
3134
- name: Setup Scala
32-
uses: olafurpg/setup-scala@v10
35+
uses: olafurpg/setup-scala@32ffa16635ff8f19cc21ea253a987f0fdf29844c
3336
with:
3437
java-version: "[email protected]"
38+
3539
# note, that task "headerCheck" defaults to just "compile:headerCheck" - see https://github.com/sbt/sbt-header/issues/14
3640
- name: SBT src licence header check
3741
run: sbt Compile/headerCheck

.github/workflows/release.yml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,17 @@ jobs:
2222
publish:
2323
runs-on: ubuntu-latest
2424
steps:
25-
- uses: actions/[email protected]
25+
- name: Checkout code
26+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8
2627
with:
2728
fetch-depth: 0
28-
- uses: olafurpg/setup-scala@v13
29+
persist-credentials: false
30+
31+
- name: Setup Scala
32+
uses: olafurpg/setup-scala@32ffa16635ff8f19cc21ea253a987f0fdf29844c
33+
with:
34+
java-version: "[email protected]"
35+
2936
- run: sbt ci-release
3037
env:
3138
PGP_PASSPHRASE: ${{ secrets.PGP_PASSPHRASE }}

0 commit comments

Comments
 (0)