Skip to content

Commit 6762c62

Browse files
committed
Fix platforms
1 parent 95c069a commit 6762c62

File tree

3 files changed

+7
-6
lines changed

3 files changed

+7
-6
lines changed

buildSrc/src/main/kotlin/PublishingHelpers.kt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,9 @@ inline fun Project.setupPublishing(
9292
setUrl("https://oss.sonatype.org/service/local/staging/deploy/maven2")
9393

9494
credentials {
95-
username = System.getenv("SONATYPE_USER")
96-
password = System.getenv("SONATYPE_KEY")
95+
username = System.getenv("SONATYPE_USER") ?: rootProject.properties["sonatype.user"]?.toString()
96+
password =
97+
System.getenv("SONATYPE_KEY") ?: rootProject.properties["sonatype.password"]?.toString()
9798
}
9899
}
99100
}

runtime/gradle/compile-native-multiplatform.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ kotlin {
88
targets {
99
def hostOs = System.getProperty("os.name")
1010

11-
def linuxEnabled = hostOs == "Mac OS X"
12-
def macosEnabled = hostOs == "Linux"
11+
def linuxEnabled = hostOs == "Linux"
12+
def macosEnabled = hostOs.startsWith("Mac")
1313
def winEnabled = hostOs.startsWith("Windows")
1414

1515
project.ext.isLinuxHost = linuxEnabled

runtime/gradle/publish.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -159,8 +159,8 @@ publishing {
159159
url = "https://oss.sonatype.org/service/local/staging/deploy/maven2"
160160

161161
credentials {
162-
username = System.getenv("SONATYPE_USER")
163-
password = System.getenv("SONATYPE_KEY")
162+
username = System.getenv("SONATYPE_USER") ?: rootProject.properties.get("sonatype.user")?.toString()
163+
password = System.getenv("SONATYPE_KEY") ?: rootProject.properties.get("sonatype.password")?.toString()
164164
}
165165
}
166166
}

0 commit comments

Comments
 (0)