Skip to content
This repository has been archived by the owner on Apr 24, 2023. It is now read-only.

Commit

Permalink
CHG corrected way of accessing singning key
Browse files Browse the repository at this point in the history
  • Loading branch information
Patrick Louis committed Nov 23, 2022
1 parent 0d4556e commit b992a91
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,15 @@ tasks.withType<KotlinCompile> {
kotlinOptions.freeCompilerArgs = listOf("-Xopt-in=kotlin.RequiresOptIn")
}

signing {
useInMemoryPgpKeys(
findProperty("signingKey").toString(),
findProperty("signingPassword").toString()
)

sign(publishing.publications)
}

publishing {
publications {
create<MavenPublication>("ktor-onelogin-saml") {
Expand Down Expand Up @@ -75,15 +84,6 @@ publishing {
}
}

signing {
val secretKey = providers.environmentVariable("SIGNING_KEY")
val signingPassword = providers.environmentVariable("SIGNING_PASSWORD")
if (secretKey.isPresent && signingPassword.isPresent)
useInMemoryPgpKeys(secretKey.get(), signingPassword.get())

sign(publishing.publications)
}

nexusPublishing {
repositories {
sonatype {
Expand Down

0 comments on commit b992a91

Please sign in to comment.