2020-11-16 00:55:04 +01:00
|
|
|
name: Build and test Minestom
|
|
|
|
|
|
|
|
on:
|
|
|
|
pull_request:
|
2023-05-06 22:18:22 +02:00
|
|
|
branches: [ main ]
|
2020-11-16 00:55:04 +01:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
2021-10-22 01:55:55 +02:00
|
|
|
- name: Set up JDK 17
|
2021-07-06 16:07:58 +02:00
|
|
|
uses: actions/setup-java@v2
|
2020-11-16 00:55:04 +01:00
|
|
|
with:
|
2021-10-22 01:55:55 +02:00
|
|
|
distribution: 'zulu'
|
|
|
|
java-version: 17
|
2020-11-16 00:55:04 +01:00
|
|
|
- name: Grant execute permission for gradlew
|
|
|
|
run: chmod +x gradlew
|
2020-11-19 11:40:19 +01:00
|
|
|
- name: Setup gradle cache
|
|
|
|
uses: burrunan/gradle-cache-action@v1
|
|
|
|
with:
|
|
|
|
save-generated-gradle-jars: false
|
|
|
|
save-local-build-cache: false
|
|
|
|
save-gradle-dependencies-cache: true
|
|
|
|
save-maven-dependencies-cache: true
|
|
|
|
# Ignore some of the paths when caching Maven Local repository
|
|
|
|
maven-local-ignore-paths: |
|
|
|
|
net/minestom/
|
2020-11-16 00:55:04 +01:00
|
|
|
- name: Build Minestom
|
2020-11-20 02:20:59 +01:00
|
|
|
run: ./gradlew classes testClasses
|
2020-11-20 02:11:22 +01:00
|
|
|
- name: Run Minestom tests
|
2020-11-16 00:55:04 +01:00
|
|
|
run: ./gradlew test
|