- replace paper-api with spigot-api 1.20.1, add spigot snapshots repo - bundle Adventure 4.17.0 + platform-bukkit 4.3.4 via shadowJar with relocate to com.loki.lochat.libs.kyori/gson and mergeServiceFiles - version 1.5.5-1.20.1, api-version 1.20, remove folia-supported, run-paper - single universal jar loads on Spigot/Mohist 1.20.1 and Paper 1.20.x-1.21.x (Paper is superset) - CI: add spigot-1.20.1 branch
61 lines
1.3 KiB
YAML
61 lines
1.3 KiB
YAML
name: Build & Test
|
|
|
|
on:
|
|
push:
|
|
branches: [main, develop, spigot-1.20.1]
|
|
pull_request:
|
|
branches: [main]
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
jobs:
|
|
build:
|
|
name: Build LoChat
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v6
|
|
|
|
- name: Setup JDK 21
|
|
uses: actions/setup-java@v5
|
|
with:
|
|
java-version: '21'
|
|
distribution: 'temurin'
|
|
cache: 'gradle'
|
|
|
|
- name: Setup Gradle
|
|
uses: gradle/actions/setup-gradle@v4
|
|
|
|
- name: Build & Test
|
|
run: chmod +x gradlew && ./gradlew build --no-daemon
|
|
|
|
- name: Checkstyle Report
|
|
if: always()
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: checkstyle-report
|
|
path: build/reports/checkstyle/
|
|
|
|
- name: JaCoCo Report
|
|
if: always()
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: jacoco-report
|
|
path: build/reports/jacoco/test/html/
|
|
|
|
- name: Test Results
|
|
if: always()
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: test-results
|
|
path: build/test-results/
|
|
|
|
- name: Plugin JAR
|
|
if: success()
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: LoChat-Plugin
|
|
path: build/libs/LoChat-*.jar
|