keygen fixes

This commit is contained in:
crschnick
2026-08-07 05:44:48 +00:00
parent 446b7c62bd
commit 3ba1648e07
2 changed files with 4 additions and 6 deletions
@@ -11,7 +11,6 @@ import io.xpipe.app.util.Validators;
import com.fasterxml.jackson.annotation.JsonTypeName;
import lombok.Singular;
import lombok.SneakyThrows;
import lombok.Value;
import lombok.experimental.SuperBuilder;
import lombok.extern.jackson.Jacksonized;
@@ -62,7 +61,7 @@ public class ScriptStore implements SelfReferentialStore, StatefulDataStore<Enab
return getShellDialect() == null || getShellDialect().isCompatibleTo(dialect);
}
private String assembleScript(ShellControl shellControl, boolean args) {
public String assembleScriptCall(ShellControl shellControl, boolean args) {
if (isCompatible(shellControl)) {
var raw = getTextSource().getText().withoutShebang().getValue();
if (raw.isBlank()) {
@@ -82,7 +81,6 @@ public class ScriptStore implements SelfReferentialStore, StatefulDataStore<Enab
return null;
}
@SneakyThrows
public ShellScript assembleScriptChain(ShellControl shellControl, boolean args) {
var all = queryFlattenedScripts();
@@ -91,7 +89,7 @@ public class ScriptStore implements SelfReferentialStore, StatefulDataStore<Enab
}
var r = all.stream()
.map(ref -> ref.getStore().assembleScript(shellControl, args))
.map(ref -> ref.getStore().assembleScriptCall(shellControl, args))
.filter(s -> s != null)
.toList();
if (r.isEmpty()) {
@@ -58,12 +58,12 @@ public class ScriptStoreSetup {
new ShellTerminalInitCommand() {
@Override
public Optional<String> terminalContent(ShellControl shellControl) {
var assembled = s.getStore().assembleScriptChain(shellControl, false);
var assembled = s.getStore().assembleScriptCall(shellControl, false);
if (assembled == null) {
return Optional.empty();
}
return Optional.ofNullable(assembled.getValue());
return Optional.of(assembled);
}
@Override