Skip to content

Commit 9d15a98

Browse files
committed
Attempted new Bootstrap
1 parent b8ea761 commit 9d15a98

File tree

1 file changed

+10
-7
lines changed
  • src/main/java/org/mangorage/bootstrap

1 file changed

+10
-7
lines changed

src/main/java/org/mangorage/bootstrap/Test.java

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,18 @@
66
import java.lang.reflect.Method;
77
import java.net.URLClassLoader;
88
import java.nio.file.Path;
9-
import java.util.stream.Collectors;
9+
import java.util.Set;
1010

1111
import static org.mangorage.bootstrap.Bootstrap.fetchJars;
1212

1313
public final class Test {
1414
public static void main(String[] args) {
15+
try {
16+
System.out.println("you have 15 seconds!");
17+
Thread.sleep(15_000);
18+
19+
} catch (Throwable ignored) {}
20+
1521
Path libsPath = Path.of("libraries");
1622
Path pluginsPath = Path.of("plugins");
1723

@@ -21,13 +27,10 @@ public static void main(String[] args) {
2127

2228
Configuration cfg = ModuleLayer.boot()
2329
.configuration()
24-
.resolve(
25-
plugins,
30+
.resolveAndBind(
31+
finder,
2632
ModuleFinder.of(),
27-
plugins.findAll()
28-
.stream()
29-
.map(ref -> ref.descriptor().name())
30-
.toList()
33+
Set.of()
3134
);
3235

3336

0 commit comments

Comments
 (0)