Use nio because that somehow makes things work
This commit is contained in:
parent
d1c6b746f0
commit
3d73879bed
|
@ -1,4 +1,6 @@
|
||||||
import io.gitlab.jfronny.scripts.*
|
import io.gitlab.jfronny.scripts.*
|
||||||
|
import java.nio.file.Files
|
||||||
|
import java.nio.file.Path
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
id("inceptum.application-standalone")
|
id("inceptum.application-standalone")
|
||||||
|
@ -118,12 +120,15 @@ jlink {
|
||||||
if (crosscompile) {
|
if (crosscompile) {
|
||||||
tasks.jpackage {
|
tasks.jpackage {
|
||||||
doLast {
|
doLast {
|
||||||
val src = File("/root/jpackage-out")
|
val src = Path.of("/root/jpackage-out")
|
||||||
val trg = buildDir.resolve("jpackage")
|
val trg = buildDir.resolve("jpackage").toPath()
|
||||||
trg.mkdirs()
|
Files.createDirectories(trg)
|
||||||
src.listFiles()!!.forEach {
|
Files.list(src).use {
|
||||||
println("Moving $it")
|
it.filter { Files.isRegularFile(it) }.forEach {
|
||||||
it.renameTo(trg.resolve(src.name))
|
val t = trg.resolve(it.fileName.toString())
|
||||||
|
println("Moving $it to $t")
|
||||||
|
Files.move(it, t)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue