File tree Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -31,6 +31,12 @@ private void configureAndroidLibrary(Project project) {
3131 project. android {
3232 defaultConfig {
3333 versionName rootProject. findProperty(' VERSION_NAME' )
34+ if (project. hasProperty(' signingKeyId' )) {
35+ System . out. println (" Getting signing info from protected source." )
36+ project. ext. ' signing.keyId' = findProperty(' signingKeyId' )
37+ project. ext. ' signing.password' = findProperty(' signingPassword' )
38+ project. ext. ' signing.inMemoryKey' = findProperty(' signingInMemoryKey' )
39+ }
3440 }
3541 }
3642}
Original file line number Diff line number Diff line change @@ -105,6 +105,12 @@ afterEvaluate { project ->
105105
106106 signing {
107107 required { isReleaseBuild() && gradle. taskGraph. hasTask(" uploadArchives" ) }
108+ if (project. hasProperty(' signing.inMemoryKey' )) {
109+ def signingKey = findProperty(" signing.inMemoryKey" ). replace(" \\ n" ," \n " )
110+ def signingPassword = findProperty(" signing.password" )
111+ def keyId = findProperty(" signing.keyId" )
112+ useInMemoryPgpKeys(keyId, signingKey, signingPassword)
113+ }
108114 sign configurations. archives
109115 }
110116
You can’t perform that action at this time.
0 commit comments