From 343627fb402ede6ed7f53e8c04a881f36d43a9eb Mon Sep 17 00:00:00 2001 From: Andre Dietisheim Date: Thu, 17 Oct 2024 12:14:23 +0200 Subject: [PATCH] fix: corrected component to be published, removed hacks (#251) Signed-off-by: Andre Dietisheim --- build.gradle.kts | 20 +++----------------- 1 file changed, 3 insertions(+), 17 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index 77cec2a..62268ae 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -64,10 +64,6 @@ dependencies { } -intellijPlatform { - buildSearchableOptions = false // no custom settings, see https://plugins.jetbrains.com/docs/intellij/tools-intellij-platform-gradle-plugin-faq.html#how-to-disable-building-the-searchable-options -} - tasks { wrapper { gradleVersion = providers.gradleProperty("gradleVersion").get() @@ -91,24 +87,12 @@ tasks { archiveClassifier.set("test") } - withType { - enabled = false - } - printProductsReleases { channels = listOf(ProductRelease.Channel.EAP) types = listOf(IntelliJPlatformType.IntellijIdeaCommunity) untilBuild = provider { null } } - // infamous hack, see https://github.com/gradle-nexus/publish-plugin/issues/354 - assemble { - doLast { - println("************************ GENERATING FAKE JAR FOR PUBLISHING TO NEXUS *************************************************") - file("${layout.buildDirectory.get().asFile.absolutePath}/libs/intellij-common-${version}-searchableOptions.jar").writeText("...") - } - } - } nexusPublishing { @@ -133,7 +117,9 @@ val testArtifact = artifacts.add("archives", testJarFile) { publishing { publications { create("mavenJava") { - from(components["java"]) + from(components["intellijPlatform"]) + artifact(tasks.named("sourcesJar")) + artifact(tasks.named("javadocJar")) artifact(testArtifact) pom { name.set("IntelliJ Common")