Now I use this way:
plugins {
val kotlinVersion: String by project
val springBootPluginVersion: String by project
val springDependencyManagementPluginVersion: String by project
id("org.jetbrains.kotlin.plugin.allopen") version kotlinVersion
id("org.jetbrains.kotlin.jvm") version kotlinVersion
id("org.springframework.boot") version springBootPluginVersion
id("io.spring.dependency-management") version springDependencyManagementPluginVersion
}
This variant compiles and works, but I don't know is this way right and why IntelliJ IDEA shows error on lines where placed versions definitions:
'val Build_gradle.project: Project' can't be called in this context by implicit receiver. Use the explicit one if necessary