mirror of
https://github.com/xpipe-io/xpipe.git
synced 2026-06-22 06:19:02 -04:00
Search path for terminals on windows as well
This commit is contained in:
@@ -109,13 +109,17 @@ public interface ExternalTerminalType extends PrefsChoiceValue {
|
||||
|
||||
@Override
|
||||
public void launch(String name, String file) throws Exception {
|
||||
var path = determineInstallation();
|
||||
if (path.isEmpty()) {
|
||||
throw new IOException("Unable to find installation of " + toTranslatedString());
|
||||
var location = determineFromPath();
|
||||
if (location.isEmpty()) {
|
||||
location = determineInstallation();
|
||||
if (location.isEmpty()) {
|
||||
throw new IOException("Unable to find installation of " + toTranslatedString());
|
||||
}
|
||||
}
|
||||
|
||||
Optional<Path> finalLocation = location;
|
||||
ApplicationHelper.executeLocalApplication(
|
||||
sc -> createCommand(sc, name, path.get().toString(), file), false);
|
||||
sc -> createCommand(sc, name, finalLocation.get().toString(), file), false);
|
||||
}
|
||||
|
||||
protected abstract String createCommand(ShellControl shellControl, String name, String path, String file);
|
||||
|
||||
Reference in New Issue
Block a user