Hello,
I am currenty using convention plugin. In my convention.gradle.kts I am using one plugin
plugins {
application
jacoco
id("nu.studer.credentials")
}
My build.gradle.kts unde buildSrc is as follows:
plugins {
`kotlin-dsl`
id("com.github.ben-manes.versions") version "0.36.0"
}
dependencies{
implementation("nu.studer:gradle-credentials-plugin:3.0")
}
I am trying to add version catelog to remove hardcoded version from dependency section here. I added a libs.versions.toml file
in gradle folder
[plugins]
nu-studer-credentials = { id = "nu.studer.credentials", version = "3.0" }
setting.gradle.kts in buildSrc folder:
dependencyResolutionManagement {
versionCatalogs {
create("libs") {
from(files("../gradle/libs.versions.toml"))
}
}
}
Now while refractoring build.gradle.kts (under buildSrc) I am getting error on “libs” as unrecorgnized reference.
plugins {
`kotlin-dsl`
id("com.github.ben-manes.versions") version "0.36.0"
alias(libs.nu.studer.credentials)
}
dependencies{
implementation(libs.plugins.nu.studer.credentials)
}
Could someone please point me to right direction here.
Regards,