We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5f2cf93 commit 2c1c17eCopy full SHA for 2c1c17e
library/maven/update.kt
@@ -1,6 +1,8 @@
1
package library.maven
2
3
+import java.lang.System.lineSeparator
4
import java.nio.file.Files
5
+import java.nio.file.Files.write
6
import java.nio.file.Paths
7
8
fun main() {
@@ -15,7 +17,7 @@ fun main() {
15
17
val snapshotNew = snapshotUpdateProc.inputStream
16
18
.use { inStr -> inStr.reader().readLines() }
19
.toSortedSet()
- Files.write(snapshotFile, snapshotNew.joinToString(System.lineSeparator()).toByteArray())
20
+ write(snapshotFile, (snapshotNew.joinToString(lineSeparator()) + lineSeparator()).toByteArray())
21
if (snapshotUpdateProc.exitValue() != 0) {
22
throw RuntimeException("'$snapshotCommand' failed with exit code '${snapshotUpdateProc.exitValue()}'")
23
}
0 commit comments