Skip to content

Commit 8423c94

Browse files
authored
Merge pull request #146 from microsoftgraph/credentials-loading-task
Load credentials and signing info from local.properties
2 parents f982948 + b5482d9 commit 8423c94

File tree

1 file changed

+7
-9
lines changed

1 file changed

+7
-9
lines changed

build.gradle

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -295,15 +295,13 @@ def customizePom(pom) {
295295
}
296296

297297
gradle.taskGraph.whenReady { taskGraph ->
298-
if (taskGraph.allTasks.any { it instanceof Sign }) {
299-
if (project.rootProject.file('local.properties').exists()) {
300-
Properties properties = new Properties()
301-
properties.load(project.rootProject.file('local.properties').newDataInputStream())
302-
tasks.withType(Sign)*.enabled = properties.getProperty('enableSigning').toBoolean()
303-
allprojects { ext."signing.keyId" = properties.getProperty('signing.keyId') }
304-
allprojects { ext."signing.secretKeyRingFile" = properties.getProperty('signing.secretKeyRingFile') }
305-
allprojects { ext."signing.password" = properties.getProperty('signing.password') }
306-
}
298+
if (project.rootProject.file('local.properties').exists()) {
299+
Properties properties = new Properties()
300+
properties.load(project.rootProject.file('local.properties').newDataInputStream())
301+
tasks.withType(Sign)*.enabled = properties.getProperty('enableSigning').toBoolean()
302+
allprojects { ext."signing.keyId" = properties.getProperty('signing.keyId') }
303+
allprojects { ext."signing.secretKeyRingFile" = properties.getProperty('signing.secretKeyRingFile') }
304+
allprojects { ext."signing.password" = properties.getProperty('signing.password') }
307305
}
308306
}
309307

0 commit comments

Comments
 (0)