File tree Expand file tree Collapse file tree 1 file changed +37
-0
lines changed
Expand file tree Collapse file tree 1 file changed +37
-0
lines changed Original file line number Diff line number Diff line change 1+ # Automatically build the project and run any configured tests for every push
2+ # and submitted pull request. This can help catch issues that only occur on
3+ # certain platforms or Java versions, and provides a first line of defence
4+ # against bad commits.
5+
6+ name : build
7+ on : [pull_request, push]
8+
9+ jobs :
10+ build :
11+ strategy :
12+ matrix :
13+ # Use these Java versions
14+ java : [
15+ 21, # Current Java LTS
16+ ]
17+ runs-on : ubuntu-22.04
18+ steps :
19+ - name : checkout repository
20+ uses : actions/checkout@v4
21+ - name : validate gradle wrapper
22+ uses : gradle/actions/wrapper-validation@v4
23+ - name : setup jdk ${{ matrix.java }}
24+ uses : actions/setup-java@v4
25+ with :
26+ java-version : ${{ matrix.java }}
27+ distribution : ' microsoft'
28+ - name : make gradle wrapper executable
29+ run : chmod +x ./gradlew
30+ - name : build
31+ run : ./gradlew build
32+ - name : capture build artifacts
33+ if : ${{ matrix.java == '21' }} # Only upload artifacts built from latest java
34+ uses : actions/upload-artifact@v4
35+ with :
36+ name : Artifacts
37+ path : build/libs/
You can’t perform that action at this time.
0 commit comments