Skip to content

Commit aff780f

Browse files
author
ahmetduruer
committed
fix
1 parent d1fc1a1 commit aff780f

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

build.gradle.kts

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,8 @@ tasks {
107107

108108
build {
109109
dependsOn("copyJar")
110+
// Ensure standard jar is built for Maven publishing
111+
dependsOn(jar)
110112
}
111113

112114
register("buildDev") {
@@ -151,8 +153,10 @@ application {
151153
mainClass.set(appMainClass)
152154
}
153155

154-
tasks.named("jar").configure {
155-
enabled = defaultJarEnabled.toBoolean()
156+
tasks.named<Jar>("jar") {
157+
// Keep jar enabled for Maven publishing
158+
enabled = true
159+
// Don't add custom naming here - let it use standard naming for publishing
156160
}
157161

158162
java {
@@ -188,8 +192,10 @@ publishing {
188192
artifactId = "core"
189193
version = project.version.toString()
190194

191-
from(components["java"])
192-
// Sources and Javadoc JARs are automatically included via withSourcesJar() and withJavadocJar()
195+
// Use the standard jar task output
196+
artifact(tasks.named("jar"))
197+
artifact(tasks.named("sourcesJar"))
198+
artifact(tasks.named("javadocJar"))
193199

194200
pom {
195201
name.set("Parsek")

0 commit comments

Comments
 (0)