Skip to content

Commit 9393e4f

Browse files
committed
Use logger
1 parent 6acc807 commit 9393e4f

File tree

1 file changed

+17
-1
lines changed
  • build-plugins/build-support/src/main/kotlin/aws/sdk/kotlin/gradle/dsl

1 file changed

+17
-1
lines changed

build-plugins/build-support/src/main/kotlin/aws/sdk/kotlin/gradle/dsl/Publish.kt

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,7 @@ fun Project.configureJReleaser() {
320320
)
321321

322322
if (!requiredVariables.all { System.getenv(it).isNotBlank() }) {
323-
println("Skipping JReleaser configuration, missing one or more required environment variables: ${requiredVariables.joinToString()}")
323+
logger.info("Skipping JReleaser configuration, missing one or more required environment variables: ${requiredVariables.joinToString()}")
324324
return
325325
}
326326

@@ -361,6 +361,7 @@ fun Project.configureJReleaser() {
361361
url = "https://central.sonatype.com/api/v1/publisher"
362362
stagingRepository(rootProject.layout.buildDirectory.dir("m2").get().toString())
363363
artifacts {
364+
verifyPom = false // Sonatype already verifies POMs, and JReleaser's validator is not compatible with TOML or klib types.
364365
artifactOverride {
365366
artifactId = "version-catalog"
366367
jar = false // Version catalogs don't produce a JAR
@@ -376,6 +377,21 @@ fun Project.configureJReleaser() {
376377
}
377378
}
378379

380+
internal fun Project.configureJReleaserKotlinNativeOverrides() {
381+
val nativePublications = tasks.withType<AbstractPublishToMaven>().filter {
382+
it.publication.name in ALLOWED_KOTLIN_NATIVE_PUBLICATION_NAMES
383+
}
384+
extensions.configure<JReleaserExtension> {
385+
deploy {
386+
maven {
387+
mavenCentral {
388+
389+
}
390+
}
391+
}
392+
}
393+
}
394+
379395
internal fun isAvailableForPublication(project: Project, publication: MavenPublication): Boolean {
380396
var shouldPublish = true
381397

0 commit comments

Comments
 (0)