https://kotlinlang.org logo
Title
t

tim

06/19/2020, 12:57 PM
Hi all, i'm trying to setup one of my kotlin projects with git submodules like so:
build.gradle.kts
projects/api
...
projects/core <-- a git submodule
projects/core/gradle.build.kts // file in question
Normally, I have the parent project specify plugin dependency versions. This works fine for everything except for core. Because Core is a submodule I can clone it and work on it in isolation, where in that case I need to specify plugin versions:
kotlin("jvm") version("...") apply(true)
but when core is consumed as a submodule and the parent project specifies the version i get a build error from gradle:
Plugin request for plugin already on the classpath must not include a version
Any suggestions on how to approach/workaround this?
👀 1
n

no

06/20/2020, 7:06 AM
what happens when you don't include the version?
t

tim

06/20/2020, 6:14 PM
If no version is included I get a build error:
Plugin [id: 'org.jetbrains.kotlin.jvm'] was not found in any of the following sources:
g

gildor

06/21/2020, 3:22 PM
If it git submodule, it’s probably a separate gradle project, cannot be included as gradle module in multimodule project (by adding include to settings.gradle), you should probably use composite build instead
t

tim

06/21/2020, 5:09 PM
Will check them out thanks