Skip to content

Commit 64059c2

Browse files
committed
Copy all dependencies
1 parent 235710d commit 64059c2

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

tiny-cli/src/main/kotlin/com/github/minigdx/tiny/cli/command/ExportDesktopCommand.kt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ import kotlinx.serialization.json.Json
1414
import kotlinx.serialization.json.decodeFromStream
1515
import java.io.File
1616
import java.io.FileInputStream
17+
import java.net.URLClassLoader
1718
import java.nio.file.Files
1819
import java.nio.file.StandardCopyOption
1920

@@ -245,9 +246,9 @@ class ExportDesktopCommand : CliktCommand(name = "export-desktop") {
245246

246247
private fun getDependencies(): List<String> {
247248
val classPath = System.getProperty("java.class.path")
248-
return classPath.split(File.pathSeparator)
249+
return classPath.split(":")
249250
.filter { it.endsWith(".jar") }
250-
.filter { !it.contains("tiny-cli") } // Exclude the CLI jar as it's already copied
251+
.filter { !it.contains("tiny-cli-") } // Exclude the CLI jar as it's already copied
251252
.distinct()
252253
}
253254

0 commit comments

Comments
 (0)