``` Cannot resolve external dependency org.jetbrai...
# announcements
m
Copy code
Cannot resolve external dependency org.jetbrains.kotlin:kotlin-gradle-plugin:1.3.31 because no repositories are defined.
Required by:
    project :
Copy code
allprojects {
    repositories {
        mavenCentral()
        jcenter()
    }
}

plugins {
    kotlin("jvm") version "1.3.31"
}
^this is my build.gradle.tks in root folder, what is wrong?
d
I think the
plugins
block doesn't like the way you declared those repositories
Try putting repositories in the child project's script
m
Plugins go into buildscripts section, not allprojects
Yeah, put mavencentral&jcenter into
buildscipt/repositories
block
m
well, does anyone have an example where he has multiple modules with
gradle.kts
? I am dealing with gradle errors all day
d
In your settings.gradle.kts:
Copy code
pluginManagement {
    repositories {
        mavenCentral()
    }
}
g
It's not necessary, Kotlin Gradle plugin is available on Gradle Plugins Portal
Maybe you could share some sample project, this config looks fine
Do you have some config in settings.gradle.kts?