jean
02/07/2023, 8:41 AMUnresolved reference
wherever the library is referencing a generated class/function. What am I suppose to do to tell the publish gradle task to also publish the generated code?tapchicoma
02/07/2023, 8:42 AMjean
02/07/2023, 8:42 AMbuild
task works all right thoughpublishing {
repositories {
maven {
url = uri("<https://maven.pkg.jetbrains.space/>...")
name = "space"
credentials(PasswordCredentials::class)
}
}
}
This is the mpp related gradle stuff :
kotlin {
jvm {
attributes.attribute(testFrameworkAttribute, "backend")
mavenPublication {
artifactId = "backend"
}
}
android {
attributes.attribute(testFrameworkAttribute, "android")
publishLibraryVariants("release", "debug")
}
ios {
binaries {
framework {
baseName = "SharedCode"
}
}
}
js(IR) {
browser {
distribution {
directory = File("$projectDir/output/")
}
}
}
sourceSets {
val commonMain by getting {
dependencies { ... }
kotlin.srcDir("build/generated/ksp/metadata/commonMain/kotlin")
}
val commonTest by getting { ... }
val jvmMain by getting { ... }
val jvmTest by getting { ... }
val androidMain by getting { ... }
val androidTest by getting { ... }
val iosMain by getting { ... }
val iosTest by getting
val jsMain by getting { ... }
val jsTest by getting { ... }
}
}
dependencies {
add("kspCommonMainMetadata", "com.jeantuffier.statemachine:processor:$stateMachineVersion")
}
tapchicoma
02/07/2023, 12:21 PMjean
02/08/2023, 8:48 AMpublishAllPublicationsToGithubRepository
I get the following error :
e: .../statemachine-library-test/src/commonMain/kotlin/test/jeantuffier/HomeStateMachine.kt:12:33 Unresolved reference: HomeScreenActions
tapchicoma
02/08/2023, 9:04 PMtasks.named("compileKotlinJvm") {
dependsOn(tasks.named("kspCommonMainKotlinMetadata"))
}
Generally looks like KSP bugjean
02/10/2023, 6:13 PM./gradlew build
. Thanks for the help!Unresolved reference
exceptiontasks.named("publishAllPublicationsToSpaceRepository") {
dependsOn(tasks.named("kspCommonMainKotlinMetadata"))
}