#1179 Resolves issue with JMBE Creator running on OSX. (#1262)

Co-authored-by: Dennis Sheirer <dsheirer@github.com>
This commit is contained in:
Denny Sheirer
2022-05-24 03:57:33 -04:00
committed by GitHub
parent fce0ae33e7
commit ceda189260

View File

@@ -25,6 +25,12 @@ import io.github.dsheirer.jmbe.github.Release;
import io.github.dsheirer.util.FileUtil; import io.github.dsheirer.util.FileUtil;
import io.github.dsheirer.util.OSType; import io.github.dsheirer.util.OSType;
import io.github.dsheirer.util.ThreadPool; import io.github.dsheirer.util.ThreadPool;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.nio.file.Files;
import java.nio.file.Path;
import java.nio.file.Paths;
import javafx.application.Platform; import javafx.application.Platform;
import javafx.beans.property.BooleanProperty; import javafx.beans.property.BooleanProperty;
import javafx.beans.property.SimpleBooleanProperty; import javafx.beans.property.SimpleBooleanProperty;
@@ -37,13 +43,6 @@ import org.rauschig.jarchivelib.ArchiverFactory;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.nio.file.Files;
import java.nio.file.Path;
import java.nio.file.Paths;
/** /**
* Creates the JMBE library by downloading the JMBE Creator CLI application from GitHub and executing it. * Creates the JMBE library by downloading the JMBE Creator CLI application from GitHub and executing it.
*/ */
@@ -147,7 +146,7 @@ public class JmbeCreator
OSType osType = OSType.getCurrentOSType(); OSType osType = OSType.getCurrentOSType();
if(osType.isLinux()) if(osType.isLinux() || osType.isOsx())
{ {
script = FileUtil.findFile(unzipped, CREATOR_SCRIPT_LINUX); script = FileUtil.findFile(unzipped, CREATOR_SCRIPT_LINUX);
} }
@@ -156,6 +155,7 @@ public class JmbeCreator
script = FileUtil.findFile(unzipped, CREATOR_SCRIPT_WINDOWS); script = FileUtil.findFile(unzipped, CREATOR_SCRIPT_WINDOWS);
} }
if(script != null) if(script != null)
{ {
ProcessBuilder processBuilder = new ProcessBuilder(); ProcessBuilder processBuilder = new ProcessBuilder();