Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ jobs:
- name: Publish to Central Portal
uses: burrunan/gradle-cache-action@663fbad34e03c8f12b27f4999ac46e3d90f87eca # v3
with:
arguments: publishPlugins publishAllPublicationsToCentralPortal
arguments: publishPlugins publishAggregationToCentralPortal
# language=properties
properties: |
release=true
Expand Down
14 changes: 14 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,10 @@
import org.gradle.plugins.ide.idea.model.IdeaProject
import org.jetbrains.gradle.ext.CopyrightConfiguration
import org.jetbrains.gradle.ext.ProjectSettings
import java.time.Duration

plugins {
id("com.gradleup.nmcp.aggregation")
id("org.jetbrains.gradle.plugin.idea-ext")
}

Expand All @@ -39,6 +41,18 @@ allprojects {
version = buildVersion
}

nmcpAggregation {
val centralPortalPublishingType = providers.gradleProperty("centralPortalPublishingType").orElse("AUTOMATIC")
val centralPortalPublishingTimeout = providers.gradleProperty("centralPortalPublishingTimeout").map { it.toLong() }.orElse(60)

centralPortal {
username = providers.environmentVariable("CENTRAL_PORTAL_USERNAME")
password = providers.environmentVariable("CENTRAL_PORTAL_PASSWORD")
publishingType = centralPortalPublishingType
validationTimeout = centralPortalPublishingTimeout.map { Duration.ofMinutes(it) }
}
}

val licenseHeader = file("gradle/license-header.txt").readText()

fun IdeaProject.settings(configuration: ProjectSettings.() -> kotlin.Unit) =
Expand Down
2 changes: 1 addition & 1 deletion buildSrc/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ dependencies {
api("com.gradle.plugin-publish:com.gradle.plugin-publish.gradle.plugin:1.3.1")
api("org.gradle.kotlin.kotlin-dsl:org.gradle.kotlin.kotlin-dsl.gradle.plugin:$expectedKotlinDslPluginsVersion")
api("org.jetbrains.dokka-javadoc:org.jetbrains.dokka-javadoc.gradle.plugin:2.0.0")
api("com.gradleup.nmcp:com.gradleup.nmcp.gradle.plugin:0.1.5")
api("com.gradleup.nmcp:com.gradleup.nmcp.gradle.plugin:1.3.0")
implementation("org.jetbrains.kotlin:kotlin-gradle-plugin")
subprojects.forEach {
runtimeOnly(project(it.path))
Expand Down
10 changes: 0 additions & 10 deletions buildSrc/src/main/kotlin/build.publish-to-central.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ java {

val release = providers.gradleProperty("release").getOrElse("false").toBoolean()
val useInMemoryPgpKeys = providers.gradleProperty("useInMemoryPgpKeys").getOrElse("true").toBoolean()
val centralPortalPublishingType = providers.gradleProperty("centralPortalPublishingType").orElse("AUTOMATIC")
val centralPortalPublishingTimeout = providers.gradleProperty("centralPortalPublishingTimeout").map { it.toLong() }

if (!release) {
publishing {
Expand Down Expand Up @@ -62,14 +60,6 @@ if (!release) {
)
}
}
nmcp {
centralPortal {
username = providers.environmentVariable("CENTRAL_PORTAL_USERNAME")
password = providers.environmentVariable("CENTRAL_PORTAL_PASSWORD")
publishingType = centralPortalPublishingType.get()
verificationTimeout = Duration.ofMinutes(centralPortalPublishingTimeout.get())
}
}
}

publishing {
Expand Down
Loading