Add all library jars

This commit is contained in:
Stef Tervelde
2025-07-02 21:25:52 +02:00
parent 772567c540
commit b165d0a511
2 changed files with 3 additions and 1 deletions
@@ -84,6 +84,8 @@ class GradleService(
private fun setupGradle(): MutableList<String> {
val sketch = sketch ?: throw IllegalStateException("Sketch is not set")
// TODO: if sketch is read-only, copy it whole to the temporary working directory / sketch
val unsaved = sketch.code
.map { code ->
val file = workingDir.resolve("unsaved/${code.fileName}")
@@ -44,7 +44,7 @@ abstract class DependenciesTask: DefaultTask() {
library.jars.forEach { jar ->
jar.classes.forEach { className ->
if (className.startsWith(statement)) {
dependencies.add(jar.path)
dependencies.addAll(library.jars.map { it.path } )
return@import
}
}