Skip to content

Commit 87f21aa

Browse files
Heiko KieselWeltraumschaf
authored andcommitted
Only apply signing for non-snapshot versions
Signed-off-by: Heiko Kiesel <heiko.kiesel@iteratec.com>
1 parent 301a12b commit 87f21aa

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

build.gradle

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -112,10 +112,12 @@ jacocoTestReport {
112112

113113
// https://docs.gradle.org/current/userguide/signing_plugin.html
114114
signing {
115-
String signingKey = System.getenv("SIGNING_KEY")
116-
String signingPassword = System.getenv("SIGNING_PASSWORD")
117-
useInMemoryPgpKeys(signingKey, signingPassword)
118-
sign publishing.publications.jar
115+
if (!version.endsWith('SNAPSHOT')) { // only sign non-snapshot versions
116+
String signingKey = System.getenv("SIGNING_KEY")
117+
String signingPassword = System.getenv("SIGNING_PASSWORD")
118+
useInMemoryPgpKeys(signingKey, signingPassword)
119+
sign publishing.publications.jar
120+
}
119121
}
120122

121123
// https://github.com/johnrengelman/shadow/issues/718

0 commit comments

Comments
 (0)