2024-01-02 01:08:26 +00:00
|
|
|
name: Run Tests
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
2024-01-02 01:22:05 +00:00
|
|
|
- "*"
|
2024-01-02 02:11:54 +00:00
|
|
|
tags:
|
|
|
|
- "v*"
|
2024-01-02 01:08:26 +00:00
|
|
|
jobs:
|
|
|
|
maven-tests:
|
2024-01-02 13:39:07 +00:00
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
os: [ubuntu-latest, windows-latest]
|
|
|
|
runs-on: ${{ matrix.os }}
|
2024-01-02 01:08:26 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout Repository
|
2024-01-02 01:27:49 +00:00
|
|
|
uses: actions/checkout@v4
|
2024-01-02 01:08:26 +00:00
|
|
|
|
|
|
|
- name: Setup JDK 21
|
2024-01-02 01:27:49 +00:00
|
|
|
uses: actions/setup-java@v4
|
2024-01-02 01:08:26 +00:00
|
|
|
with:
|
|
|
|
java-version: 21
|
|
|
|
distribution: temurin
|
|
|
|
cache: maven
|
|
|
|
|
2024-01-02 01:33:37 +00:00
|
|
|
- name: Check versions
|
|
|
|
run: |
|
|
|
|
java -version
|
|
|
|
javac -version
|
2024-01-02 13:39:07 +00:00
|
|
|
./mvnw -version
|
2024-01-02 01:31:50 +00:00
|
|
|
|
2024-01-02 01:08:26 +00:00
|
|
|
- name: Test with Maven
|
2024-01-02 13:39:07 +00:00
|
|
|
run: ./mvnw -B verify --file pom.xml
|
2024-01-02 01:51:37 +00:00
|
|
|
|
2024-01-02 13:39:07 +00:00
|
|
|
- name: Build Linux DEB Package for Release
|
|
|
|
if: ${{ startsWith(github.ref, 'refs/tags/') && runner.os == 'Linux' }}
|
2024-01-02 02:09:37 +00:00
|
|
|
run: ./scripts/package-linux-deb.sh
|
|
|
|
|
2024-01-02 13:39:07 +00:00
|
|
|
- name: Build Windows MSI Package for Release
|
|
|
|
if: ${{ startsWith(github.ref, 'refs/tags/') && runner.os == 'Windows' }}
|
2024-01-02 13:40:20 +00:00
|
|
|
run: powershell.exe -File scripts/package-windows-msi.ps1
|
2024-01-02 13:39:07 +00:00
|
|
|
|
2024-01-02 02:09:37 +00:00
|
|
|
- name: Create Release
|
2024-01-02 02:17:11 +00:00
|
|
|
if: ${{ startsWith(github.ref, 'refs/tags/') }}
|
2024-01-02 02:09:37 +00:00
|
|
|
uses: softprops/action-gh-release@v1
|
|
|
|
with:
|
2024-01-02 13:39:07 +00:00
|
|
|
fail_on_unmatched_files: false
|
2024-01-02 02:09:37 +00:00
|
|
|
files: |
|
|
|
|
*.deb
|