Skip to content

Commit

Permalink
Add signing plugin for publishing
Browse files Browse the repository at this point in the history
  • Loading branch information
boswelja committed Sep 30, 2023
1 parent 46ced77 commit da6cd68
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
8 changes: 8 additions & 0 deletions core/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ plugins {
alias(libs.plugins.dokka)

id("maven-publish")
id("signing")
}
group = "io.github.boswelja.menuprovider"
version = "1.0.2"
Expand Down Expand Up @@ -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") {
Expand Down
8 changes: 8 additions & 0 deletions material3/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ plugins {
alias(libs.plugins.dokka)

id("maven-publish")
id("signing")
}

group = "io.github.boswelja.menuprovider"
Expand Down Expand Up @@ -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") {
Expand Down

0 comments on commit da6cd68

Please sign in to comment.