From df630fec541e71ce4ee6c1f4d662f390ad06fb35 Mon Sep 17 00:00:00 2001 From: Aminda Suomalainen Date: Sun, 24 Aug 2025 14:31:34 +0300 Subject: [PATCH] flatpak-workarounds.bash: set TZ for Steam under systemd (and remove empty line) --- bash/flatpak-workarounds.bash | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/bash/flatpak-workarounds.bash b/bash/flatpak-workarounds.bash index 66c97cf..14e9a4a 100755 --- a/bash/flatpak-workarounds.bash +++ b/bash/flatpak-workarounds.bash @@ -35,7 +35,6 @@ flatpak override --filesystem=/run/udev $@ # MangoHUD for everything that has it flatpak override --env=MANGOHUD=1 $@ flatpak override --env=MANGOHUD_CONFIG='read_cfg,background_alpha=0,battery_time,battery,cpu_temp,display_server,font_size=26,gpu_temp,device_battery_icon,device_battery=gamepad+mouse,fan,horizontal,ram,vram,swap,time,time_no_label,time_format=%T,wine,mangoapp_steam,position=bottom-left' $@ - flatpak override --filesystem=xdg-config/MangoHud $@ # and of course we are Steam Deck everywhere, no question about it! flatpak override --env=SteamDeck=1 $@ @@ -85,6 +84,15 @@ flatpak override --talk-name=org.freedesktop.impl.portal.desktop.darkman $@ # Additional SDKs (`flatpak search org.freedesktop.Sdk.Extension`) flatpak override --env=FLATPAK_ENABLE_SDK_EXT=texlive,dotnet,golang $@ +# If timedatectl (systemd) is used, set TZ for flatpaks needing it +if hash timedatectl 2> /dev/null; then + # DRY - Don't Repeat Yourself + export TZ=$(timedatectl show --property=Timezone --value) + # https://github.com/flathub/com.valvesoftware.Steam/wiki#steam-shows-times-with-incorrect-timezone + flatpak override com.valvesoftware.Steam --env=TZ=$TZ $@ + flatpak override com.valvesoftware.SteamLink --env=TZ=$TZ $@ +fi + # I don't have other nvim on SteamOS #flatpak override io.neovim.nvim --filesystem=host $@ #flatpak override io.neovim.nvim --filesystem=host-os $@