Skip to content

Commit 9c32cf9

Browse files
committed
ci: add build CI (with artifacts)
1 parent 5137a25 commit 9c32cf9

1 file changed

Lines changed: 41 additions & 0 deletions

File tree

.github/workflows/build.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: Build
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
# Cancel in-progress builds
10+
concurrency:
11+
group: ${{ github.workflow }}-${{ github.ref }}
12+
cancel-in-progress: true
13+
14+
jobs:
15+
build:
16+
runs-on: ubuntu-latest
17+
18+
steps:
19+
- name: Checkout repository
20+
uses: actions/checkout@v4
21+
22+
- name: Validate Gradle wrapper
23+
uses: gradle/actions/wrapper-validation@v3
24+
25+
- name: Set up JDK (Temurin 21)
26+
uses: actions/setup-java@v4
27+
with:
28+
distribution: "temurin"
29+
java-version: "21"
30+
cache: "gradle"
31+
32+
- name: Build with Gradle
33+
run: ./gradlew build --no-daemon
34+
35+
- name: Upload build artifacts
36+
uses: actions/upload-artifact@v4
37+
with:
38+
name: plugin-${{ github.sha }}
39+
path: build/libs/*.jar # Upload all generated jars
40+
retention-days: 30
41+
if-no-files-found: error

0 commit comments

Comments
 (0)