From da6cd68e95624367e587abeaadfb12675478f3eb Mon Sep 17 00:00:00 2001 From: "Jack Boswell (boswelja)" Date: Sat, 30 Sep 2023 18:14:58 +1300 Subject: [PATCH] Add signing plugin for publishing --- core/build.gradle.kts | 8 ++++++++ material3/build.gradle.kts | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/core/build.gradle.kts b/core/build.gradle.kts index f502587..17e049a 100644 --- a/core/build.gradle.kts +++ b/core/build.gradle.kts @@ -11,6 +11,7 @@ plugins { alias(libs.plugins.dokka) id("maven-publish") + id("signing") } group = "io.github.boswelja.menuprovider" version = "1.0.2" @@ -66,6 +67,13 @@ detekt { basePath = rootDir.absolutePath } +signing { + val signingKey: String? by project + val signingPassword: String? by project + useInMemoryPgpKeys(signingKey, signingPassword) + sign(publishing.publications) +} + publishing { repositories { if (System.getenv("PUBLISHING") == "true") { diff --git a/material3/build.gradle.kts b/material3/build.gradle.kts index 0dce694..351c4e6 100644 --- a/material3/build.gradle.kts +++ b/material3/build.gradle.kts @@ -11,6 +11,7 @@ plugins { alias(libs.plugins.dokka) id("maven-publish") + id("signing") } group = "io.github.boswelja.menuprovider" @@ -66,6 +67,13 @@ detekt { basePath = rootDir.absolutePath } +signing { + val signingKey: String? by project + val signingPassword: String? by project + useInMemoryPgpKeys(signingKey, signingPassword) + sign(publishing.publications) +} + publishing { repositories { if (System.getenv("PUBLISHING") == "true") {