Browse Source

Fix signing settings when no Keychain is specified (#1093)

Closes #1086
pull/1151/head
Mitchell Syer 3 years ago committed by GitHub
parent
commit
5b34141cbe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      gradle-plugins/compose/src/main/kotlin/org/jetbrains/compose/desktop/application/internal/validation/ValidatedMacOSSigningSettings.kt

2
gradle-plugins/compose/src/main/kotlin/org/jetbrains/compose/desktop/application/internal/validation/ValidatedMacOSSigningSettings.kt

@ -44,10 +44,10 @@ internal fun MacOSSigningSettings.validate(
val signIdentity = this.identity.orNull val signIdentity = this.identity.orNull
?: error(ERR_UNKNOWN_SIGN_ID) ?: error(ERR_UNKNOWN_SIGN_ID)
val keychainPath = this.keychain.orNull val keychainPath = this.keychain.orNull
if (keychainPath != null) {
val keychainFile = val keychainFile =
listOf(project.file(keychainPath), project.rootProject.file(keychainPath)) listOf(project.file(keychainPath), project.rootProject.file(keychainPath))
.firstOrNull { it.exists() } .firstOrNull { it.exists() }
if (keychainPath != null) {
check(keychainFile != null && keychainFile.exists()) { check(keychainFile != null && keychainFile.exists()) {
"$ERR_PREFIX could not find the specified keychain: $keychainPath" "$ERR_PREFIX could not find the specified keychain: $keychainPath"
} }

Loading…
Cancel
Save