Configure ShadowJar for fat jar generation and update workflow
Some checks failed
Build JStom / build (push) Failing after 38s
Some checks failed
Build JStom / build (push) Failing after 38s
This commit is contained in:
@@ -29,10 +29,10 @@ jobs:
|
||||
run: chmod +x gradlew
|
||||
|
||||
- name: Build with Gradle
|
||||
run: ./gradlew build
|
||||
run: ./gradlew shadowJar
|
||||
|
||||
- name: Upload Artifact
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: JStom-Jar
|
||||
path: build/libs/*.jar
|
||||
name: JStom-FatJar
|
||||
path: build/libs/jstom-1.0-SNAPSHOT.jar
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
plugins {
|
||||
id("java")
|
||||
id("application")
|
||||
id("com.github.johnrengelman.shadow") version "8.1.1"
|
||||
}
|
||||
|
||||
group = "net.jstom"
|
||||
@@ -30,6 +31,13 @@ application {
|
||||
mainClass.set("net.jstom.Main")
|
||||
}
|
||||
|
||||
tasks {
|
||||
shadowJar {
|
||||
mergeServiceFiles()
|
||||
archiveClassifier.set("") // Remove '-all' suffix so it replaces the default jar or just sits nicely
|
||||
}
|
||||
}
|
||||
|
||||
java {
|
||||
toolchain {
|
||||
languageVersion.set(JavaLanguageVersion.of(25))
|
||||
|
||||
Reference in New Issue
Block a user