GP-0: JAVA_HOME_OVERRIDE now works if it's surrounded by double quotes

This commit is contained in:
Ryan Kurtz
2026-06-12 13:07:26 -04:00
parent 4982080ee7
commit ec7136f913

View File

@@ -91,7 +91,11 @@ public class LaunchProperties {
public File getJavaHomeOverride() {
List<String> javaHome = propertyMap.get(JAVA_HOME_OVERRIDE);
if (javaHome != null && !javaHome.isEmpty()) {
return new File(javaHome.get(0));
String path = javaHome.get(0).trim();
if (path.length() > 2 && path.startsWith("\"") && path.endsWith("\"")) {
path = path.substring(1, path.length() - 1);
}
return new File(path);
}
return null;
}