From 5fc73644f41b600efbc64108c8541e636b7c87cb Mon Sep 17 00:00:00 2001 From: crschnick Date: Thu, 14 Aug 2025 09:34:24 +0000 Subject: [PATCH] Fixes [stage] --- app/src/main/java/io/xpipe/app/core/AppExtensionManager.java | 4 ++-- app/src/main/java/io/xpipe/app/core/AppProperties.java | 2 +- app/src/main/java/io/xpipe/app/core/check/AppAvCheck.java | 3 ++- .../main/java/io/xpipe/app/core/check/AppDebugModeCheck.java | 2 +- .../io/xpipe/app/core/check/AppHomebrewCoreutilsCheck.java | 3 ++- .../java/io/xpipe/app/core/check/AppJavaOptionsCheck.java | 3 ++- app/src/main/java/io/xpipe/app/core/check/AppShellCheck.java | 3 ++- .../java/io/xpipe/app/core/check/AppTestCommandCheck.java | 3 ++- app/src/main/java/io/xpipe/app/ext/ExtensionException.java | 5 +++-- app/src/main/java/io/xpipe/app/prefs/AppPrefs.java | 4 ++-- build.gradle | 2 +- dist/jpackage.gradle | 2 +- version | 2 +- 13 files changed, 22 insertions(+), 16 deletions(-) diff --git a/app/src/main/java/io/xpipe/app/core/AppExtensionManager.java b/app/src/main/java/io/xpipe/app/core/AppExtensionManager.java index fd0b443ec..6dff5867a 100644 --- a/app/src/main/java/io/xpipe/app/core/AppExtensionManager.java +++ b/app/src/main/java/io/xpipe/app/core/AppExtensionManager.java @@ -56,7 +56,7 @@ public class AppExtensionManager { return INSTANCE; } - private static String getLocalInstallVersion(AppInstallation localInstallation) throws Exception { + private static String getLocalInstallVersion(AppInstallation localInstallation) { var exec = localInstallation.getDaemonExecutablePath(); var out = LocalExec.readStdoutIfPossible(exec.toString(), "version"); return out.orElseThrow().strip(); @@ -81,7 +81,7 @@ public class AppExtensionManager { Path p = localInstallation.getBaseInstallationPath(); if (!Files.exists(p)) { throw new IllegalStateException( - "Required local XPipe installation was not found but is required for development. See https://github" + "Required local " + AppNames.ofCurrent().getName() + " installation was not found but is required for development. See https://github" + ".com/xpipe-io/xpipe/blob/master/CONTRIBUTING.md#development-setup"); } diff --git a/app/src/main/java/io/xpipe/app/core/AppProperties.java b/app/src/main/java/io/xpipe/app/core/AppProperties.java index ef69587ce..ec788ea3d 100644 --- a/app/src/main/java/io/xpipe/app/core/AppProperties.java +++ b/app/src/main/java/io/xpipe/app/core/AppProperties.java @@ -110,7 +110,6 @@ public class AppProperties { return p; }) .orElse(defaultDataDir); - dataBinDir = dataDir.resolve("bin"); showcase = Optional.ofNullable(System.getProperty(AppNames.propertyName("showcase"))) .map(Boolean::parseBoolean) .orElse(false); @@ -139,6 +138,7 @@ public class AppProperties { // We require the user dir from here AppUserDirectoryCheck.check(dataDir); AppCache.setBasePath(dataDir.resolve("cache")); + dataBinDir = dataDir.resolve("cache", "bin"); UUID id = AppCache.getNonNull("uuid", UUID.class, () -> null); if (id == null) { uuid = UUID.randomUUID(); diff --git a/app/src/main/java/io/xpipe/app/core/check/AppAvCheck.java b/app/src/main/java/io/xpipe/app/core/check/AppAvCheck.java index ad49404e8..7cfa41868 100644 --- a/app/src/main/java/io/xpipe/app/core/check/AppAvCheck.java +++ b/app/src/main/java/io/xpipe/app/core/check/AppAvCheck.java @@ -4,6 +4,7 @@ import io.xpipe.app.comp.Comp; import io.xpipe.app.comp.base.MarkdownComp; import io.xpipe.app.comp.base.ModalButton; import io.xpipe.app.comp.base.ModalOverlay; +import io.xpipe.app.core.AppNames; import io.xpipe.app.core.AppProperties; import io.xpipe.app.core.AppResources; import io.xpipe.app.util.WindowsRegistry; @@ -71,7 +72,7 @@ public class AppAvCheck { BITDEFENDER("Bitdefender") { @Override public String getDescription() { - return "Bitdefender sometimes isolates XPipe and some shell programs, effectively making it unusable."; + return "Bitdefender sometimes isolates " + AppNames.ofCurrent().getName() + " and some shell programs, effectively making it unusable."; } @Override diff --git a/app/src/main/java/io/xpipe/app/core/check/AppDebugModeCheck.java b/app/src/main/java/io/xpipe/app/core/check/AppDebugModeCheck.java index 22c56f13f..cf63506e5 100644 --- a/app/src/main/java/io/xpipe/app/core/check/AppDebugModeCheck.java +++ b/app/src/main/java/io/xpipe/app/core/check/AppDebugModeCheck.java @@ -16,7 +16,7 @@ public class AppDebugModeCheck { """ **************************************** - * You are running XPipe in debug mode! * + * You are running in debug mode! * * The debug console output can contain * * sensitive information and secrets. * * Don't share this output via an * diff --git a/app/src/main/java/io/xpipe/app/core/check/AppHomebrewCoreutilsCheck.java b/app/src/main/java/io/xpipe/app/core/check/AppHomebrewCoreutilsCheck.java index 23b00b00f..4cd9eff85 100644 --- a/app/src/main/java/io/xpipe/app/core/check/AppHomebrewCoreutilsCheck.java +++ b/app/src/main/java/io/xpipe/app/core/check/AppHomebrewCoreutilsCheck.java @@ -1,5 +1,6 @@ package io.xpipe.app.core.check; +import io.xpipe.app.core.AppNames; import io.xpipe.app.issue.ErrorEventFactory; import io.xpipe.core.FilePath; import io.xpipe.core.OsType; @@ -33,7 +34,7 @@ public class AppHomebrewCoreutilsCheck { ErrorEventFactory.fromMessage( "You have the homebrew coreutils package installed and added to your PATH at " + loc.get() + "." - + " The coreutils commands overwrite and are incompatible to the native macOS commands, which XPipe expects." + + " The coreutils commands overwrite and are incompatible to the native macOS commands, which " + AppNames.ofCurrent().getName() + " expects." + " Please remove the coreutils commands from your PATH prior to launching XPipe.") .term() .handle(); diff --git a/app/src/main/java/io/xpipe/app/core/check/AppJavaOptionsCheck.java b/app/src/main/java/io/xpipe/app/core/check/AppJavaOptionsCheck.java index d0c1c8830..f709476cb 100644 --- a/app/src/main/java/io/xpipe/app/core/check/AppJavaOptionsCheck.java +++ b/app/src/main/java/io/xpipe/app/core/check/AppJavaOptionsCheck.java @@ -1,6 +1,7 @@ package io.xpipe.app.core.check; import io.xpipe.app.core.AppCache; +import io.xpipe.app.core.AppNames; import io.xpipe.app.issue.ErrorEventFactory; public class AppJavaOptionsCheck { @@ -18,7 +19,7 @@ public class AppJavaOptionsCheck { ErrorEventFactory.fromMessage( "You have configured the global environment variable _JAVA_OPTIONS=%s on your system." .formatted(env) - + " This will forcefully apply all custom JVM options to XPipe and can cause a variety of different issues." + + " This will forcefully apply all custom JVM options to " + AppNames.ofCurrent().getName() + " and can cause a variety of different issues." + " Please remove this global environment variable and use local configuration instead for your other JVM programs.") .expected() .handle(); diff --git a/app/src/main/java/io/xpipe/app/core/check/AppShellCheck.java b/app/src/main/java/io/xpipe/app/core/check/AppShellCheck.java index a907060e0..03b0006a4 100644 --- a/app/src/main/java/io/xpipe/app/core/check/AppShellCheck.java +++ b/app/src/main/java/io/xpipe/app/core/check/AppShellCheck.java @@ -1,5 +1,6 @@ package io.xpipe.app.core.check; +import io.xpipe.app.core.AppNames; import io.xpipe.core.OsType; public class AppShellCheck { @@ -58,7 +59,7 @@ public class AppShellCheck { protected String modifyOutput(String output) { if (output.contains("is not recognized as an internal or external command") && output.contains("exec-")) { - return "Unable to create temporary script files. XPipe needs to be able to create shell script files that can be launched " + return "Unable to create temporary script files. " + AppNames.ofCurrent().getName() + " needs to be able to create shell script files that can be launched " + "by a terminal emulator to make terminal launches work."; } diff --git a/app/src/main/java/io/xpipe/app/core/check/AppTestCommandCheck.java b/app/src/main/java/io/xpipe/app/core/check/AppTestCommandCheck.java index 2083b7c16..a3df63ed5 100644 --- a/app/src/main/java/io/xpipe/app/core/check/AppTestCommandCheck.java +++ b/app/src/main/java/io/xpipe/app/core/check/AppTestCommandCheck.java @@ -1,6 +1,7 @@ package io.xpipe.app.core.check; import io.xpipe.app.core.AppInstallation; +import io.xpipe.app.core.AppNames; import io.xpipe.app.process.ProcessOutputException; import io.xpipe.app.util.LocalShell; import io.xpipe.core.OsType; @@ -23,7 +24,7 @@ public class AppTestCommandCheck { .execute(); } catch (ProcessOutputException ex) { throw ProcessOutputException.withPrefix( - "Installation self test failed. Is your \"test\" shell command working as expected and is the XPipe installation directory " + "Installation self test failed. Is your \"test\" shell command working as expected and is the " + AppNames.ofCurrent().getName() + " installation directory " + "accessible?", ex); } diff --git a/app/src/main/java/io/xpipe/app/ext/ExtensionException.java b/app/src/main/java/io/xpipe/app/ext/ExtensionException.java index 178dc7df9..c7d1532e4 100644 --- a/app/src/main/java/io/xpipe/app/ext/ExtensionException.java +++ b/app/src/main/java/io/xpipe/app/ext/ExtensionException.java @@ -1,6 +1,7 @@ package io.xpipe.app.ext; import io.xpipe.app.core.AppInstallation; +import io.xpipe.app.core.AppNames; public class ExtensionException extends RuntimeException { @@ -26,10 +27,10 @@ public class ExtensionException extends RuntimeException { try { var loc = AppInstallation.ofCurrent().getBaseInstallationPath(); var full = - message + ".\n\n" + "Please check whether the XPipe installation data at " + loc + " is corrupted."; + message + ".\n\n" + "Please check whether the " + AppNames.ofCurrent().getName() + " installation data at " + loc + " is corrupted."; return new ExtensionException(full, cause); } catch (Throwable t) { - var full = message + ".\n\n" + "Please check whether the XPipe installation data is corrupted."; + var full = message + ".\n\n" + "Please check whether the " + AppNames.ofCurrent().getName() + " installation data is corrupted."; return new ExtensionException(full, cause); } } diff --git a/app/src/main/java/io/xpipe/app/prefs/AppPrefs.java b/app/src/main/java/io/xpipe/app/prefs/AppPrefs.java index 67fdbe8ab..90814588a 100644 --- a/app/src/main/java/io/xpipe/app/prefs/AppPrefs.java +++ b/app/src/main/java/io/xpipe/app/prefs/AppPrefs.java @@ -353,11 +353,11 @@ public final class AppPrefs { return alwaysShowSshMotd; } - public final ObservableBooleanValue preferTerminalTabs() { + public ObservableBooleanValue preferTerminalTabs() { return preferTerminalTabs; } - public final ObservableValue> getIconSources() { + public ObservableValue> getIconSources() { return iconSources; } diff --git a/build.gradle b/build.gradle index 811d1942f..5cd08a99b 100644 --- a/build.gradle +++ b/build.gradle @@ -94,7 +94,7 @@ def getJvmArgs() { def jvmRunArgs = [ "-Dio.xpipe.app.arch=$arch", "-Dfile.encoding=UTF-8", - "-Dvisualvm.display.name=XPipe", + "-Dvisualvm.display.name=$productName", "-Djavafx.preloader=io.xpipe.app.core.AppPreloader", "-Djdk.virtualThreadScheduler.parallelism=8" ] diff --git a/dist/jpackage.gradle b/dist/jpackage.gradle index 3ce3aae40..5b09cbb0e 100644 --- a/dist/jpackage.gradle +++ b/dist/jpackage.gradle @@ -17,7 +17,7 @@ def releaseArguments = distJvmArgs + [ ] if (org.gradle.internal.os.OperatingSystem.current().isMacOsX()) { - releaseArguments += '-Xdock:name=XPipe' + releaseArguments += "-Xdock:name=$productName" } if (isFullRelease || isStage) { diff --git a/version b/version index 075816fa0..14a2667a8 100644 --- a/version +++ b/version @@ -1 +1 @@ -18.0-14 +18.0-15