Merge pull request #503 from aclist/fix/flatpak-fixes

fix: flatpak fixes
This commit is contained in:
aclist authored and GitHub committed 2026-10-26 17:22:58 +09:00
commit 5134bf02fb
3 files changed
+10 -6

No files matched your search

+1 -1
View File
@@ -17,7 +17,7 @@ DZGUI follows a specific set of guidelines, enumerated below:
- Provide a free and open-source tool under GPL
- Do not use undocumented, third-party servers to aggregate data; no central "DZGUI" server
- All connections go to Steam and DayZ servers directly; the tool should function in perpetuity without intermediary endpoints
- Target Linux desktop and Steam deck specifically; not a cross-platform tool
- Target Linux desktop and Steam Deck specifically; not a cross-platform tool
## Setup and usage
+6 -5
View File
@@ -173,11 +173,12 @@ class Shortcuts:
self.save_shortcuts()
def save_shortcuts(self) -> None:
try:
backup = self.shortcuts_path.with_suffix(".vdf.bak")
shutil.copy(self.shortcuts_path, backup)
except Exception as e:
logger.critical(e)
if self.shortcuts_path.is_file():
try:
backup = self.shortcuts_path.with_suffix(".vdf.bak")
shutil.copy(self.shortcuts_path, backup)
except Exception as e:
logger.critical(e)
try:
with open(self.shortcuts_path, "wb") as f:
vdf.binary_dump(self.shortcuts, f)
+3
View File
@@ -3,11 +3,14 @@ import shutil
import subprocess
from dzgui.const.constants import APP_NAME, FLATPAK_APPID, FLATPAK_CMD, STEAM_CMD
from dzgui.init.proc import is_sandboxed
logger = logging.getLogger(APP_NAME)
def has_flatpak_client() -> bool:
if is_sandboxed():
return True
try:
res = subprocess.run(
[FLATPAK_CMD, "list", "--columns=application"],