diff options
| author | copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> | 2026-02-04 01:43:47 +0000 |
|---|---|---|
| committer | copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> | 2026-02-04 01:43:47 +0000 |
| commit | b5d610d8bbdc2ad9c5075fad4e5cdee23f780102 (patch) | |
| tree | 8fbc4bdc225b3f0e4717c514e742a287f2a719ca | |
| parent | 704f636418d1f7f06bda264fdb525e10e1138e28 (diff) | |
| download | decky-installer-b5d610d8bbdc2ad9c5075fad4e5cdee23f780102.tar.gz decky-installer-b5d610d8bbdc2ad9c5075fad4e5cdee23f780102.zip | |
Add Decky Loader installation check for SteamOS
Co-authored-by: tranch <5999732+tranch@users.noreply.github.com>
| -rw-r--r-- | user_install_script.sh | 32 |
1 files changed, 22 insertions, 10 deletions
diff --git a/user_install_script.sh b/user_install_script.sh index d9c2773..42f8123 100644 --- a/user_install_script.sh +++ b/user_install_script.sh @@ -6,21 +6,33 @@ DECKY_MIRROR_HOST="__DECKY_MIRROR_HOST__" DECKY_PLUGIN_MIRROR_HOST="__DECKY_PLUGIN_MIRROR_HOST__" DECKY_PLUGIN_TARGET_ID="__DECKY_PLUGIN_ID__" +# Check if Decky Loader is already installed and running on SteamOS +echo "Checking if Decky Loader is already installed and running..." +if systemctl is-active --quiet plugin_loader.service 2>/dev/null; then + echo "Decky Loader (plugin_loader.service) is already running. Skipping Decky Loader installation." + SKIP_DECKY_INSTALL=true +else + echo "Decky Loader is not running or not installed. Proceeding with installation." + SKIP_DECKY_INSTALL=false +fi + # Download the official installer script, rewrite domains to the mirror, then execute. # This keeps the original installer logic intact while swapping network endpoints. tmp_script="/tmp/decky_user_install_script.sh" -if ! curl -fsSL "https://${DECKY_MIRROR_HOST}/SteamDeckHomebrew/decky-installer/releases/latest/download/user_install_script.sh" \ - | sed -E \ - -e "s#github\.com#${DECKY_MIRROR_HOST}#g" \ - -e "s#api\.github\.com#api.${DECKY_MIRROR_HOST}#g" \ - -e "s#raw\.githubusercontent\.com/([^/]+)/([^/]+)/([^/]+)/#${DECKY_MIRROR_HOST}/\1/\2/plain/#g" \ - > "${tmp_script}"; then - echo "Failed to download or rewrite the official installer script." >&2 - exit 1 -fi +if [ "$SKIP_DECKY_INSTALL" = false ]; then + if ! curl -fsSL "https://${DECKY_MIRROR_HOST}/SteamDeckHomebrew/decky-installer/releases/latest/download/user_install_script.sh" \ + | sed -E \ + -e "s#github\.com#${DECKY_MIRROR_HOST}#g" \ + -e "s#api\.github\.com#api.${DECKY_MIRROR_HOST}#g" \ + -e "s#raw\.githubusercontent\.com/([^/]+)/([^/]+)/([^/]+)/#${DECKY_MIRROR_HOST}/\1/\2/plain/#g" \ + > "${tmp_script}"; then + echo "Failed to download or rewrite the official installer script." >&2 + exit 1 + fi -bash "${tmp_script}" + bash "${tmp_script}" +fi # Download and run decky plugin installer helper (mirror-hosted). plugin_installer="/tmp/decky_plugin_installer.py" |
