Property springBootVersion not setting version in buildSrc

- Fixes #1148
This commit is contained in:
Janne Valkealahti
2024-03-15 12:16:14 +00:00
parent 451f12ab14
commit d76f9dc8c6

View File

@@ -13,11 +13,16 @@ repositories {
}
ext {
def propertiesFile = new File(new File("$projectDir").parentFile, "gradle.properties")
propertiesFile.withInputStream {
def properties = new Properties()
properties.load(it)
set("springBootVersion", properties["springBootVersion"])
if (project.hasProperty('springBootVersion')) {
set("springBootVersion", springBootVersion)
}
else {
def propertiesFile = new File(new File("$projectDir").parentFile, "gradle.properties")
propertiesFile.withInputStream {
def properties = new Properties()
properties.load(it)
set("springBootVersion", properties["springBootVersion"])
}
}
}