From 4fff23a47fe0b0e0cddc4d74c810df27b851754a Mon Sep 17 00:00:00 2001 From: maxjivi05 Date: Sun, 4 Oct 2026 22:34:40 -0400 Subject: [PATCH] Steam language: set the client's language from the app's before every start --- .../com/droiddeck/launcher/session/SessionFiles.kt | 1 + .../linuxfs/overlay/usr/local/bin/droiddeck-session | 12 ++++++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/com/droiddeck/launcher/session/SessionFiles.kt b/app/src/main/java/com/droiddeck/launcher/session/SessionFiles.kt index 1a0d935cd..5d1055eb5 100644 --- a/app/src/main/java/com/droiddeck/launcher/session/SessionFiles.kt +++ b/app/src/main/java/com/droiddeck/launcher/session/SessionFiles.kt @@ -41,6 +41,7 @@ object SessionFiles { "usr/local/bin/droiddeck-clipboard" to "usr/local/bin/droiddeck-clipboard", "usr/local/bin/droiddeck-steam-install" to "usr/local/bin/droiddeck-steam-install", "usr/local/bin/droiddeck-steam-ui-scale" to "usr/local/bin/droiddeck-steam-ui-scale", + "usr/local/bin/droiddeck-steam-language" to "usr/local/bin/droiddeck-steam-language", "usr/local/bin/droiddeck-steam-library" to "usr/local/bin/droiddeck-steam-library", "usr/local/bin/droiddeck-seed-redists" to "usr/local/bin/droiddeck-seed-redists", "usr/local/bin/droiddeck-proton-extra" to "usr/local/bin/droiddeck-proton-extra", diff --git a/tools/linuxfs/overlay/usr/local/bin/droiddeck-session b/tools/linuxfs/overlay/usr/local/bin/droiddeck-session index 91465d661..e551e025c 100755 --- a/tools/linuxfs/overlay/usr/local/bin/droiddeck-session +++ b/tools/linuxfs/overlay/usr/local/bin/droiddeck-session @@ -707,6 +707,10 @@ BUSCONF # and a restart below (rc=42, or the one after the ARM64 Proton lands) would otherwise start it # again on the branch it just wrote. steam_channel=${BL_STEAM_CHANNEL:-steamdeck_publicbeta} + # The app's language (Setup, or the system's): the client's interface takes -language over its + # registry, and the registry is rewritten before each start below for its update window. + _bl_lang=() + [ -n "${BL_STEAM_LANGUAGE:-}" ] && _bl_lang=(-language "$BL_STEAM_LANGUAGE") steam_beta=$steam_root/package/beta if [ -n "${BL_ADDED_GAMES:-}" ] && [ -f "$BL_ADDED_GAMES" ]; then droiddeck-steam-games watch "$steam_root" "$BL_ADDED_GAMES" & @@ -730,7 +734,7 @@ BUSCONF done ) & fi - echo "== steam args: ${_bl_ui[*]} ${_bl_cdp[*]} -clientbeta $steam_channel -no-cef-sandbox -cef-force-gpu -cef-ozone-platform=x11 -cef-use-gl=angle -cef-use-angle=vulkan $*" + echo "== steam args: ${_bl_ui[*]} ${_bl_cdp[*]} ${_bl_lang[*]} -clientbeta $steam_channel -no-cef-sandbox -cef-force-gpu -cef-ozone-platform=x11 -cef-use-gl=angle -cef-use-angle=vulkan $*" # An update that cannot install asks for a restart (rc=42) every time; the count is capped so a # session can never again loop in silence, which reads as a menu opening and closing by itself. steam_updates=0 @@ -779,8 +783,12 @@ BUSCONF echo start >> "$steam_root/package/droiddeck-unconfirmed" _bl_counted=1 fi + # Between starts only: the client holds registry.vdf in memory and writes it back on exit. + if [ -n "${BL_STEAM_LANGUAGE:-}" ]; then + droiddeck-steam-language "$HOME" "$BL_STEAM_LANGUAGE" || true + fi step "starting the Steam client${BL_STEAM_UI:+ ($BL_STEAM_UI UI)}" - "$steam_root/steamrtarm64/steam" "${_bl_ui[@]}" "${_bl_cdp[@]}" -clientbeta "$steam_channel" \ + "$steam_root/steamrtarm64/steam" "${_bl_ui[@]}" "${_bl_cdp[@]}" "${_bl_lang[@]}" -clientbeta "$steam_channel" \ -no-cef-sandbox -cef-force-gpu -cef-ozone-platform=x11 \ -cef-use-gl=angle -cef-use-angle=vulkan "$@" rc=$?