No more preview features since those broke things
This commit is contained in:
parent
31fb8b3b2a
commit
11c0a8a144
|
@ -26,7 +26,3 @@ dependencies {
|
|||
tasks.runShadow {
|
||||
args("8002")
|
||||
}
|
||||
|
||||
tasks.compileJava {
|
||||
options.compilerArgs.add("--enable-preview")
|
||||
}
|
|
@ -34,20 +34,17 @@ record PipelineUnpacker(AtomicBoolean changed) implements BiConsumer<Pipeline, C
|
|||
}
|
||||
changed.set(true);
|
||||
// Send included
|
||||
switch (include) {
|
||||
case Scalar str -> download(str.value(), null, pipelineConsumer);
|
||||
case YamlMapping map -> {
|
||||
for (YamlNode key : map.keys()) {
|
||||
download(map.string(key), key.asScalar().value(), pipelineConsumer);
|
||||
}
|
||||
//TODO switch back to switch pattern matching once that is available
|
||||
if (include instanceof Scalar str) download(str.value(), null, pipelineConsumer);
|
||||
else if (include instanceof YamlMapping map) {
|
||||
for (YamlNode key : map.keys()) {
|
||||
download(map.string(key), key.asScalar().value(), pipelineConsumer);
|
||||
}
|
||||
case YamlSequence seq -> {
|
||||
for (YamlNode node : seq) {
|
||||
download(node.asScalar().value(), null, pipelineConsumer);
|
||||
}
|
||||
} else if (include instanceof YamlSequence seq) {
|
||||
for (YamlNode node : seq) {
|
||||
download(node.asScalar().value(), null, pipelineConsumer);
|
||||
}
|
||||
default -> throw new IllegalStateException("Unexpected value: " + include);
|
||||
}
|
||||
} else throw new IllegalStateException("Unexpected value: " + include);
|
||||
// Remove include from original
|
||||
Pipeline filtered = new Pipeline();
|
||||
filtered.name = pipeline.name;
|
||||
|
|
Loading…
Reference in New Issue