Skip to content

Commit

Permalink
Use new shade plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
Kale-Ko committed Sep 3, 2024
1 parent 26dabad commit 6bd34cc
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 21 deletions.
27 changes: 7 additions & 20 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
plugins {
id "java"
id "io.github.kale_ko.gradleshade" version "1.2.0"
id "maven-publish"
}

Expand Down Expand Up @@ -52,28 +53,14 @@ jar {
}
}

tasks.register("fatJar", Jar) {
archiveClassifier = "fat"
manifest {
attributes "Name": "io/github/kale_ko/bjsl/",
"Specification-Title": "BJSL",
"Specification-Version": project.version,
"Specification-Vendor": "Kale-Ko",
"Implementation-Title": "io.github.kale_ko.bjsl",
"Implementation-Version": project.version,
"Implementation-Vendor": "Kale-Ko",
"Sealed": true
}
import io.github.kale_ko.gradleshade.ShadeMode

duplicatesStrategy = DuplicatesStrategy.EXCLUDE
from(sourceSets.main.output)
from(configurations.runtimeClasspath.collect {
it.isDirectory() ? null : zipTree(it)
})
shade {
mode = ShadeMode.EMBED_CLASSES
}

build {
finalizedBy tasks.fatJar
shadedJar {
archiveClassifier = "fat"
}

javadoc {
Expand Down Expand Up @@ -137,7 +124,7 @@ publishing {
version = project.version

artifact tasks.jar
artifact tasks.fatJar
artifact tasks.shadedJar
artifact tasks.sourcesJar
artifact tasks.javadocJar

Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ org.gradle.caching=true

java_version=11

project_version=1.11.1
project_version=1.12.0
project_description=A semi-advanced Java data serialization library with features for reducing file sizes.

jackson_version=2.17.2
9 changes: 9 additions & 0 deletions settings.gradle
Original file line number Diff line number Diff line change
@@ -1 +1,10 @@
pluginManagement {
repositories {
maven {
url "https://maven.kaleko.dev/public-snapshot/"
}
gradlePluginPortal()
}
}

rootProject.name = "BJSL"

0 comments on commit 6bd34cc

Please sign in to comment.