Skip to content

Commit 31a35a2

Browse files
committed
GHA debug
1 parent 0e657a9 commit 31a35a2

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

build-conventions/src/main/kotlin/convention.publishing-nexus.gradle.kts

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,13 @@ nexusPublishing {
88
sonatype {
99
nexusUrl by uri("https://s01.oss.sonatype.org/service/local/")
1010
snapshotRepositoryUrl by uri("https://s01.oss.sonatype.org/content/repositories/snapshots/")
11-
println("MPE: sonatypeUsername: ${findProperty("sonatypeUsername")?.let {"EXISTS"}}")
12-
println("MPE: sonatypePassword: ${findProperty("sonatypePassword")?.let {"EXISTS"}}")
11+
val checkProp = { pName: String ->
12+
val exists = findProperty("sonatypeUsername")?.toString()?.takeIf(String::isNotBlank)
13+
?.let { "EXISTS" } ?: "MISSING"
14+
printlnCI("$pName: $exists")
15+
}
16+
checkProp("sonatypeUsername")
17+
checkProp("sonatypePassword")
1318
}
1419
}
1520
}

build-conventions/src/main/kotlin/util/_global.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,5 +31,5 @@ val Project.isMainHost: Boolean
3131
get() = HostManager.simpleOsName().equals("${properties["project.mainOS"]}", true)
3232

3333
fun printlnCI(text: Any?) {
34-
if (CI) println(text)
34+
if (CI) println("[CI]: $text")
3535
}

0 commit comments

Comments
 (0)