Merge pull request #623 from PlaceholderAPI/feature/621-build-jars-on-pr

Build jars on PR (Compile and build validation)
This commit is contained in:
PiggyPiglet 2021-06-26 11:51:00 +08:00 committed by GitHub
commit 247a5cde8f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 31 additions and 0 deletions

31
.github/workflows/pr_build_jars.yml vendored Normal file
View File

@ -0,0 +1,31 @@
name: "Test compiling against Java 8, 11 and 16"
on:
pull_request:
branches:
- development
paths:
- "src/**"
- "build.gradle"
jobs:
testBuilds:
name: "Test-compile against Java 8, 11 and 16"
runs-on: ubuntu-latest
strategy:
fail-fast: false
max-parallel: 4
matrix:
java-version: [8, 11, 16]
steps:
- name: "Checkout Code"
uses: actions/checkout@v2
- name: "Prepare Java ${{ matrix.java-version }}"
uses: actions/setup-java@v2
with:
distribution: "adopt"
java-version: "${{ matrix.java-version }}"
- name: "Make build.gradle executable"
run: "chmod +x gradlew"
- name: "Build jar with Java ${{ matrix.java-version }}"
run: "./gradlew shadowJar"