janvladimirmostert
04/17/2022, 2:47 PMgradle.properties
(like coroutinesVersion=1.6.1 or kotlinVersion=1.6.20) and then inside build.gradle.kts access it somehow?
plugins {
kotlin("multiplatform").version(kotlinVersion).apply(false)
val commonMain by getting {
dependencies {
api("org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutinesVersion")
Alternatively, what is the consensus on using version catalogues (define a catalogue in the root and then keep all the module depenendency versions in sync like this)
https://docs.gradle.org/current/userguide/platforms.htmljanvladimirmostert
04/17/2022, 6:06 PMdependencyResolutionManagement {
versionCatalogs {
create("libs") {
library("kotlinx-coroutines", "org.jetbrains.kotlinx:kotlinx-coroutines-core:1.6.1")
}
}
}
implementation(libs.kotlinx.coroutines)
Matthew Gast
04/17/2022, 6:11 PMval coroutinesVersion: String by project
.Vampire
04/17/2022, 6:23 PMjanvladimirmostert
04/17/2022, 6:24 PMMatthew Gast
04/18/2022, 1:11 AMVampire
04/18/2022, 1:12 AMVampire
04/18/2022, 1:13 AMMatthew Gast
04/18/2022, 1:13 AMVampire
04/18/2022, 1:14 AMVampire
04/18/2022, 1:14 AMMatthew Gast
04/18/2022, 1:15 AMVampire
04/18/2022, 1:23 AMdependencyResolutionManagement
block is incubating.
Version catalogs themselves are already promoted to stable.Vampire
04/18/2022, 1:23 AMversionCatalogs
should be stable already, or to play super safe, just use the TOML instead.janvladimirmostert
04/18/2022, 5:12 AM