40 lines
906 B
YAML
40 lines
906 B
YAML
name: Maven Build
|
|
|
|
on: [push, pull_request]
|
|
|
|
jobs:
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout Repository
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Set up JDK 16
|
|
uses: actions/setup-java@v2
|
|
with:
|
|
java-version: 16
|
|
distribution: 'adopt'
|
|
|
|
- name: Cache Maven packages
|
|
uses: actions/cache@v2.1.5
|
|
with:
|
|
path: ~/.m2
|
|
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
|
|
restore-keys: ${{ runner.os }}-m2
|
|
|
|
- name: Build with Maven
|
|
uses: nick-invision/retry@v2
|
|
with:
|
|
timeout_minutes: 5
|
|
max_attempts: 3
|
|
command: mvn -B package --file pom.xml
|
|
|
|
- name: Upload artifact
|
|
uses: actions/upload-artifact@v2.2.3
|
|
with:
|
|
name: AuthmeVelocity
|
|
path: |
|
|
proxy/target/AuthMeVelocity-proxy.jar
|
|
spigot/target/AuthMeVelocity-spigot.jar |