File tree 1 file changed +12
-6
lines changed
gradle/build-logic/src/main/kotlin
1 file changed +12
-6
lines changed Original file line number Diff line number Diff line change
1
+ import java.util.*
2
+
1
3
plugins {
2
4
id(" org.gradle.maven-publish" )
3
5
id(" org.gradle.signing" )
@@ -39,12 +41,11 @@ publishing {
39
41
}
40
42
}
41
43
42
- (System .getProperty(" signing.privateKey" ) ? : System .getenv(" SIGNING_PRIVATE_KEY" ))?.let {
43
- String (java.util.Base64 .getDecoder().decode(it)).trim()
44
- }?.let { key ->
45
- signing {
46
- val signingPassword = System .getProperty(" signing.password" ) ? : System .getenv(" SIGNING_PASSWORD" )
47
- useInMemoryPgpKeys(key, signingPassword)
44
+ signing {
45
+ val signingKey: String? by project
46
+ val signingPassword: String? by project
47
+ signingKey?.let {
48
+ useInMemoryPgpKeys(String (Base64 .getDecoder().decode(it)).trim(), signingPassword)
48
49
sign(publishing.publications)
49
50
}
50
51
}
@@ -54,3 +55,8 @@ val signingTasks = tasks.withType<Sign>()
54
55
tasks.withType<AbstractPublishToMaven >().configureEach {
55
56
dependsOn(signingTasks)
56
57
}
58
+
59
+ tasks.withType<AbstractArchiveTask >().configureEach {
60
+ isPreserveFileTimestamps = false
61
+ isReproducibleFileOrder = true
62
+ }
You can’t perform that action at this time.
0 commit comments