Skip to content

Commit fe5a320

Browse files
committed
feat(build): Integrate shadow plugin for JAR packaging and update release configuration
1 parent bd7d986 commit fe5a320

File tree

3 files changed

+13
-2
lines changed

3 files changed

+13
-2
lines changed

.releaserc.json

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,19 @@
1111
"@semantic-release/exec",
1212
{
1313
"verifyConditionsCmd": "./gradlew check",
14-
"publishCmd": "./gradlew -Pversion=${nextRelease.version} publish && echo '${nextRelease.version}' > version.txt"
14+
"publishCmd": "./gradlew -Pversion=${nextRelease.version} shadowJar"
1515
}
1616
],
1717
"@semantic-release/git",
1818
[
1919
"@semantic-release/github",
2020
{
21-
"assets": [],
21+
"assets": [
22+
{
23+
"path": "build/libs/BlueMapS3Storage-*.jar",
24+
"label": "BlueMapS3Storage.jar"
25+
}
26+
],
2227
"labels": false,
2328
"failTitle": false,
2429
"failComment": false,

build.gradle.kts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
plugins {
22
id("java")
33
alias(libs.plugins.spotless)
4+
alias(libs.plugins.shadow)
45
}
56

67
dependencies {
@@ -16,6 +17,9 @@ tasks {
1617
test {
1718
useJUnitPlatform()
1819
}
20+
shadowJar {
21+
archiveClassifier.set("")
22+
}
1923
}
2024

2125
java {

settings.gradle.kts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ dependencyResolutionManagement {
1111
version("spotless", "7.2.1")
1212
version("aws-java-nio-spi-for-s3", "2.2.1")
1313
version("bluemap", "5.3")
14+
version("shadow", "9.0.1")
1415

1516
library("nio-spi-s3", "software.amazon.nio.s3", "aws-java-nio-spi-for-s3").versionRef("aws-java-nio-spi-for-s3")
1617
library("bluemap.core", "de.bluecolored.bluemap", "BlueMapCore").versionRef("bluemap")
@@ -21,6 +22,7 @@ dependencyResolutionManagement {
2122
library("junit.platform.launcher", "org.junit.platform", "junit-platform-launcher").withoutVersion()
2223

2324
plugin("spotless", "com.diffplug.spotless").versionRef("spotless")
25+
plugin("shadow", "com.gradleup.shadow").versionRef("shadow")
2426
}
2527
}
2628
}

0 commit comments

Comments
 (0)