-
Notifications
You must be signed in to change notification settings - Fork 0
42 lines (42 loc) · 1.05 KB
/
gradle.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
name: Java CI with Gradle
on:
push:
branches:
- main
pull_request:
branches:
- main
permissions:
contents: read
jobs:
build:
runs-on: windows-latest
strategy:
matrix:
version: [ 'Lab1', 'Lab2', 'Lab3', 'Lab4' ]
steps:
- uses: actions/checkout@main
- name: Set up JDK 21
uses: actions/setup-java@main
with:
java-version: '21'
distribution: temurin
- name: Setup Gradle
uses: gradle/actions/setup-gradle@main
- name: Build with Gradle
run: ./gradlew :app${{matrix.version}}:build
- name: Upload Artifact
uses: actions/upload-artifact@main
with:
name: compiled-artifact-${{github.run_number}}-${{github.run_id }}
overwrite: true
path: ./app${{matrix.version}}/build/libs/*.jar
merge:
runs-on: windows-latest
needs: build
steps:
- name: Merge Artifacts
uses: actions/upload-artifact/merge@main
with:
name: compiled-artifact
delete-merged: true