-
-
Notifications
You must be signed in to change notification settings - Fork 32
54 lines (50 loc) · 1.51 KB
/
maven-verify.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
name: Maven verify
on:
pull_request:
jobs:
verify:
runs-on: ubuntu-latest
permissions:
pull-requests: write
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up JDK
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'adopt'
- name: Cache maven packages
uses: actions/cache@v4
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2
- name: Run the maven verify
run: mvn --batch-mode --update-snapshots clean verify
- name: Save the PR number in a file
run: echo ${{ github.event.number }} > PR_NUMBER.txt
- name: Upload the PR number as an artifact
uses: actions/upload-artifact@v4.5.0
with:
name: PR_NUMBER
path: PR_NUMBER.txt
- uses: marocchino/sticky-pull-request-comment@v2.9.1
with:
message: |
Please check on sonarcloud <https://sonarcloud.io/project/pull_requests_list?id=io.github.mivek%3AmetarParser> that the PR does not add any issue.
generate-docs:
runs-on: ubuntu-latest
needs: verify
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up JDK
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'adopt'
- name: Generate the javadoc
run: mvn --batch-mode javadoc:javadoc