mirror of
https://github.com/ethauvin/kobalt.git
synced 2025-04-26 00:17:11 -07:00
Better version parsing.
This commit is contained in:
parent
ce32785de7
commit
446901283d
1 changed files with 3 additions and 2 deletions
|
@ -37,9 +37,10 @@ class KFiles {
|
|||
// kobalt-wrapper.properties: kobalt.version=0.827
|
||||
// When Kobalt can't find the newest jar file, it will instead use the classes produced by IDEA
|
||||
// in the directories specified here:
|
||||
val previousVersion = "0." + (Kobalt.version.split(".")[1].toInt() - 1).toString()
|
||||
val leftSuffix = Kobalt.version.substring(0, Kobalt.version.lastIndexOf(".") + 1)
|
||||
val previousVersion = leftSuffix + (Kobalt.version.split(".")[1].toInt() - 1).toString()
|
||||
val previousJar = joinDir(distributionsDir, "kobalt-" + previousVersion,
|
||||
"kobalt/wrapper/kobalt-" + previousVersion + ".jar")
|
||||
"kobalt/wrapper/kobalt-$previousVersion.jar")
|
||||
val result = listOf("", "modules/kobalt-plugin-api", "modules/wrapper").map {
|
||||
File(homeDir(KFiles.joinDir("kotlin", "kobalt", it, "kobaltBuild", "classes")))
|
||||
.absolutePath
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue