-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
23 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,60 +9,51 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repo | ||
uses: actions/checkout@v2 | ||
uses: actions/checkout@v4 | ||
- name: Install Gradle | ||
uses: sdkman/sdkman-action@main | ||
with: | ||
candidate: gradle | ||
version: 8.9 | ||
|
||
- name: Generate Gradle wrapper | ||
run: gradle wrapper | ||
|
||
- name: Grant execute permission for gradlew | ||
run: chmod +x gradlew | ||
|
||
- name: Restore Maven Local Cache | ||
id: cache-maven-restore | ||
uses: actions/cache/restore@v4 | ||
with: | ||
path: ~/.m2/repository | ||
key: maven-${{ runner.os }}-${{ hashFiles('**/*.gradle*', '**/settings.gradle') }} | ||
restore-keys: | | ||
maven-${{ runner.os }}- | ||
- name: Set up JDK 16 | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: 16 | ||
distribution: 'adopt' | ||
|
||
- name: Cache Gradle dependencies | ||
uses: actions/cache@v3 | ||
with: | ||
path: | | ||
~/.gradle/caches | ||
~/.gradle/wrapper | ||
key: gradle-${{ runner.os }}-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} | ||
restore-keys: | | ||
gradle-${{ runner.os }}- | ||
- name: Compile Spigot 1.16.5-1.17.x | ||
uses: SpraxDev/[email protected] | ||
with: | ||
versions: "1.16.5,1.17,1.17.1" | ||
|
||
- name: Remap 1.17 | ||
run: ./gradlew nms:nms_v1_17:remap | ||
run: ./gradlew nms_v1_17:remap | ||
|
||
- name: Remap 1.17.1 | ||
run: ./gradlew nms:nms_v1_17_1:remap | ||
run: ./gradlew nms_v1_17_1:remap | ||
|
||
- name: Set up JDK 17 | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: 17 | ||
distribution: 'adopt' | ||
|
||
- name: Cache Gradle dependencies | ||
uses: actions/cache@v3 | ||
with: | ||
path: | | ||
~/.gradle/caches | ||
~/.gradle/wrapper | ||
key: gradle-${{ runner.os }}-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} | ||
restore-keys: | | ||
gradle-${{ runner.os }}- | ||
- name: Compile Spigot 1.18.x | ||
uses: SpraxDev/[email protected] | ||
with: | ||
|
@@ -83,24 +74,23 @@ jobs: | |
java-version: 21 | ||
distribution: 'adopt' | ||
|
||
- name: Cache Gradle dependencies | ||
uses: actions/cache@v3 | ||
with: | ||
path: | | ||
~/.gradle/caches | ||
~/.gradle/wrapper | ||
key: gradle-${{ runner.os }}-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} | ||
restore-keys: | | ||
gradle-${{ runner.os }}- | ||
- name: Build with Gradle | ||
run: ./gradlew build | ||
|
||
- name: Save Maven Local Cache | ||
id: cache-maven-save | ||
uses: actions/cache/save@v4 | ||
with: | ||
path: ~/.m2/repository | ||
key: ${{ steps.cache-maven-restore.outputs.cache-primary-key }} | ||
|
||
- name: Upload artifacts | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: Lusk.jar | ||
path: build/libs/*.jar | ||
|
||
|
||
test_build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
|