Skip to content

Commit a1599de

Browse files
committed
Added a build action [2429]
1 parent 4976fba commit a1599de

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# GOAL: Verify that the code builds without error.
2+
3+
name: "Build the code"
4+
5+
on:
6+
push:
7+
branches:
8+
- main
9+
pull_request:
10+
types: [opened, synchronize, reopened]
11+
12+
jobs:
13+
build:
14+
name: Build
15+
runs-on: ubuntu-latest
16+
steps:
17+
- uses: actions/checkout@v2
18+
with:
19+
fetch-depth: 0
20+
- name: Set up JDK 21
21+
uses: actions/setup-java@v1
22+
with:
23+
java-version: 21
24+
- name: Cache Maven packages
25+
uses: actions/cache@v3
26+
with:
27+
path: ~/.m2
28+
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
29+
restore-keys: ${{ runner.os }}-m2
30+
- name: Build and analyze
31+
run: mvn clean verify -Pci
32+
env:
33+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
34+
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}

0 commit comments

Comments
 (0)