Skip to content

Commit

Permalink
fix: fallback to $XDG_DATA_HOME instead of $HOME/.local/share for Fla…
Browse files Browse the repository at this point in the history
…tpak (#290)

* umu_consts: fallback to $XDG_DATA_HOME for umu Flatpak

* flatpak: add filesystem permission xdg-data/umu:create
  • Loading branch information
R1kaB3rN authored Dec 29, 2024
1 parent 2c47b04 commit 59a82ea
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions packaging/flatpak/org.openwinecomponents.umu.umu-launcher.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@ finish-args:
# Pressure Vessel
# See https://github.com/flathub/com.valvesoftware.Steam/commit/0538256facdb0837c33232bc65a9195a8a5bc750
- --env=XDG_DATA_DIRS=/app/share:/usr/lib/extensions/vulkan/share:/usr/share:/usr/share/runtime/share:/run/host/user-share:/run/host/share:/usr/lib/pressure-vessel/overrides/share
# umu
# Use host's $XDG_DATA_HOME, otherwise Flatpak's
- --filesystem=xdg-data/umu:create

add-extensions:
org.freedesktop.Platform.Compat.i386:
Expand Down
2 changes: 1 addition & 1 deletion umu/umu_consts.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ class GamescopeAtom(Enum):
XDG_DATA_HOME: Path = (
Path(os.environ["HOST_XDG_DATA_HOME"])
if os.environ.get("HOST_XDG_DATA_HOME")
else Path.home().joinpath(".local", "share")
else Path(os.environ["XDG_DATA_HOME"])
)
elif os.environ.get("SNAP"):
XDG_DATA_HOME: Path = Path(os.environ["SNAP_REAL_HOME"])
Expand Down

0 comments on commit 59a82ea

Please sign in to comment.