Skip to content

Commit 0bcf9d8

Browse files
committed
chore: CI Improvements (#216)
Merge pull request #216 from adangel:chore/ci-improvements
2 parents 92a29a9 + 9e51a4b commit 0bcf9d8

File tree

5 files changed

+23
-15
lines changed

5 files changed

+23
-15
lines changed

.github/dependabot.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,11 @@ updates:
55
directory: "/"
66
schedule:
77
interval: "weekly"
8+
day: "wednesday"
89
# Allow up to 10 open pull requests for maven dependencies
910
open-pull-requests-limit: 10
1011
- package-ecosystem: "github-actions"
1112
directory: "/"
1213
schedule:
1314
interval: "weekly"
14-
groups:
15-
all-actions:
16-
patterns: [ "*" ]
15+
day: "wednesday"

.github/workflows/build.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@ jobs:
2222
run:
2323
shell: bash
2424
steps:
25-
- uses: actions/checkout@v4
26-
- uses: actions/setup-java@v4
25+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 #v4.2.2
26+
- uses: actions/setup-java@c5195efecf7bdfc987ee8bae7a71cb8b11521c00 #v4.7.1
2727
with:
2828
distribution: 'temurin'
2929
java-version: '11'
@@ -33,7 +33,7 @@ jobs:
3333
./mvnw --show-version --errors --batch-mode \
3434
-Pshading \
3535
verify
36-
- uses: actions/upload-artifact@v4
36+
- uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 #v4.6.2
3737
with:
3838
name: compile-artifact
3939
if-no-files-found: error

.github/workflows/publish-release.yml

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,10 @@ jobs:
3232
outputs:
3333
VERSION: ${{ steps.version.outputs.VERSION }}
3434
steps:
35-
- uses: actions/checkout@v4
35+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 #v4.2.2
3636
with:
3737
ref: ${{ github.event.workflow_run.head_branch }}
38-
- uses: actions/setup-java@v4
38+
- uses: actions/setup-java@c5195efecf7bdfc987ee8bae7a71cb8b11521c00 #v4.7.1
3939
with:
4040
distribution: 'temurin'
4141
java-version: '11'
@@ -88,10 +88,10 @@ jobs:
8888
run:
8989
shell: bash
9090
steps:
91-
- uses: actions/checkout@v4
91+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 #v4.2.2
9292
with:
9393
ref: ${{ github.event.workflow_run.head_branch }}
94-
- uses: actions/setup-java@v4
94+
- uses: actions/setup-java@c5195efecf7bdfc987ee8bae7a71cb8b11521c00 #v4.7.1
9595
with:
9696
distribution: 'temurin'
9797
java-version: '11'
@@ -118,10 +118,18 @@ jobs:
118118
END_LINE=$((END_LINE - 1))
119119
RELEASE_BODY="$(head -$END_LINE CHANGELOG.md | tail -$((END_LINE - BEGIN_LINE)))"
120120
echo "$RELEASE_BODY" > release_notes.md
121+
- uses: actions/create-github-app-token@df432ceedc7162793a195dd1713ff69aefc7379e #v2.0.6
122+
id: pmd-actions-helper-app-token
123+
with:
124+
app-id: ${{ secrets.PMD_ACTIONS_HELPER_ID }}
125+
private-key: ${{ secrets.PMD_ACTIONS_HELPER_PRIVATE_KEY }}
126+
owner: pmd
127+
repositories: pmd
128+
permission-contents: write # create a release
121129
- name: Create Release
122130
env:
123131
# Token required for GH CLI:
124-
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
132+
GH_TOKEN: ${{ steps.pmd-actions-helper-app-token.outputs.token }}
125133
TAG_NAME: ${{ github.event.workflow_run.head_branch }}
126134
VERSION: ${{ needs.check-version.outputs.VERSION }}
127135
run: |

.github/workflows/publish-snapshot.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,10 @@ jobs:
3030
outputs:
3131
VERSION: ${{ steps.version.outputs.VERSION }}
3232
steps:
33-
- uses: actions/checkout@v4
33+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 #v4.2.2
3434
with:
3535
ref: main
36-
- uses: actions/setup-java@v4
36+
- uses: actions/setup-java@c5195efecf7bdfc987ee8bae7a71cb8b11521c00 #v4.7.1
3737
with:
3838
distribution: 'temurin'
3939
java-version: '11'
@@ -77,10 +77,10 @@ jobs:
7777
run:
7878
shell: bash
7979
steps:
80-
- uses: actions/checkout@v4
80+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 #v4.2.2
8181
with:
8282
ref: main
83-
- uses: actions/setup-java@v4
83+
- uses: actions/setup-java@c5195efecf7bdfc987ee8bae7a71cb8b11521c00 #v4.7.1
8484
with:
8585
distribution: 'temurin'
8686
java-version: '11'

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
* [#169](https://github.com/pmd/pmd-designer/pull/169): \[ci] publish-snapshot/release: migrate to central portal - [Andreas Dangel](https://github.com/adangel) (@adangel)
1212
* [#170](https://github.com/pmd/pmd-designer/pull/170): \[ci] Make build a reuseable workflow - [Andreas Dangel](https://github.com/adangel) (@adangel)
1313
* [#207](https://github.com/pmd/pmd-designer/pull/207): \[ci] Cleanup old scripts - [Andreas Dangel](https://github.com/adangel) (@adangel)
14+
* [#216](https://github.com/pmd/pmd-designer/pull/216): chore: CI Improvements - [Andreas Dangel](https://github.com/adangel) (@adangel)
1415

1516
**📦 Dependency updates:**
1617
<details>

0 commit comments

Comments
 (0)