From 87ee5ff54dd1c8af8a6ded032b43b08b72443fa0 Mon Sep 17 00:00:00 2001 From: crschnick Date: Fri, 10 Apr 2026 12:14:15 +0000 Subject: [PATCH] Rework temp name for PTB --- app/src/main/java/io/xpipe/app/process/ShellTemp.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/io/xpipe/app/process/ShellTemp.java b/app/src/main/java/io/xpipe/app/process/ShellTemp.java index 89bec4a33..4712bce26 100644 --- a/app/src/main/java/io/xpipe/app/process/ShellTemp.java +++ b/app/src/main/java/io/xpipe/app/process/ShellTemp.java @@ -16,7 +16,8 @@ public class ShellTemp { // Even on macOS as root it is technically unique as only root will use /tmp if (proc.getOsType() != OsType.WINDOWS && proc.getOsType() != OsType.MACOS) { var temp = proc.getSystemTemporaryDirectory(); - base = temp.join(AppNames.ofCurrent().getKebapName()); + // Prevent interference with xpipe-* temp files + base = temp.join(AppNames.ofCurrent().getKebapName().replace("-", "_")); proc.view().mkdir(base); // We have to make sure that also other users can create files here // This command should work in all shells @@ -30,7 +31,8 @@ public class ShellTemp { .executeAndCheck(); } else { var temp = proc.getSystemTemporaryDirectory(); - base = temp.join(AppNames.ofCurrent().getKebapName()); + // Prevent interference with xpipe-* temp files + base = temp.join(AppNames.ofCurrent().getKebapName().replace("-", "_")); } return sub != null ? base.join(sub) : base; }