janvladimirmostert
06/30/2020, 8:01 PMbuild.gradle.kts
settings.gradle.kts
subprojects
+-- project-www
+-- project-a (kotlin jvm)
+-- project-b (kotlin mp jvm+js)
+-- project-c (kotlin mp jvm+js)
+-- project-d (java jvm)
+-- project-e (kotlin jvm)
inside my settings.gradle.kts (root), i've added
include("project-www")
include("project-a")
include("project-b")
...
include("project-e")
what should be going into my project-b/settings.gradle.kts
and project-b/build.gradle.kts
in order to pull in that project-d or project-e dependencies?
and then i want to include that multiplatform's JVM part in project, would i be following the same steps or should i do something different for including a multiplatform project as dependency?thanksforallthefish
07/01/2020, 11:42 AMimplementation(project(":project-e"))
as dependency in project-bthanksforallthefish
07/01/2020, 11:42 AMjanvladimirmostert
07/01/2020, 2:13 PMthanksforallthefish
07/01/2020, 2:16 PMjanvladimirmostert
07/01/2020, 2:17 PMaraqnid
07/01/2020, 3:46 PMconfigurations {
val platformAttr = Attribute.of("org.jetbrains.kotlin.platform.type", org.jetbrains.kotlin.gradle.plugin.KotlinPlatformType::class.java)
all {
attributes.attribute(platformAttr, org.jetbrains.kotlin.gradle.plugin.KotlinPlatformType.jvm)
}
}
That was necessary to make Gradle pick out the JVM output from the exported multiplatform module. Presumably if the consumer is a multiplatform project, that’s automatically added.janvladimirmostert
07/03/2020, 10:58 AMjanvladimirmostert
07/03/2020, 11:48 AMgradle build
is still failing if i run gradle build from the rootaraqnid
07/03/2020, 11:52 AMconfigurations{}
will probably resolve to the right thing even if it’s not top-level, but best to be explicit)janvladimirmostert
07/03/2020, 11:58 AMgradle build
considering IntelliJ is working but gradle build from command line is failing?janvladimirmostert
07/03/2020, 12:13 PMaraqnid
07/03/2020, 1:35 PM