Files
DroidDeck/tools/deploy_local.sh
T
The412Banner d160f464b6 Rename the app SteamDeck → DroidDeck
App name, app ID and code package: DroidDeck, com.droiddeck.launcher
(sources moved to com/droiddeck/launcher, the 68 JNI functions renamed
with them). The new app ID installs beside SteamDeck rather than over it.

Everywhere the name was the app's own: the sidebar title, the session
report, share zips, the shell title, wake-lock and log tags, User-Agents,
the Compose theme, the Download folder and switch files (droiddeck-env,
-osc, -driver, -tu-debug, -no-pad, -pad-log, -no-hud, -wlr-renderer; the
old names are not read), and inside the runtime (droiddeck-desktop,
Firefox's droiddeck.js, the shortcuts tag, the rumble socket, debug and
cache paths). Build scripts, CI artifact (droiddeck-apk), CMake project,
README and the progress log follow.

Kept on purpose: Valve's Steam Deck (the -steamdeck flag,
steamdeck_publicbeta/stable, 'Steam Deck mode', the steamos.cloud
package URLs) and names inside the hosted desktop package (steamdeck.png,
steamdeck-steam, steamdeck-bigpicture). 'Desktop installed' now tests for
labwc instead of the launcher the app stages itself. A committed
__pycache__ .pyc is removed.
2026-09-23 18:28:04 -04:00

38 lines
1.3 KiB
Bash
Executable File

#!/usr/bin/env bash
set -euo pipefail
repo_root=$(CDPATH= cd -- "$(dirname -- "${BASH_SOURCE[0]}")/.." && pwd)
sdk_dir=${ANDROID_HOME:-${ANDROID_SDK_ROOT:-"${HOME}/Library/Android/sdk"}}
adb_bin=${ADB:-${sdk_dir}/platform-tools/adb}
apk=${1:-"${repo_root}/app/build/outputs/apk/release/app-release.apk"}
if [[ ! -x "${adb_bin}" ]]; then
echo "adb not found at ${adb_bin}; set ADB or ANDROID_HOME." >&2
exit 1
fi
if [[ ! -f "${apk}" ]]; then
echo "APK not found at ${apk}; run tools/build_local.sh first." >&2
exit 1
fi
if [[ -n "${ADB_SERIAL:-}" ]]; then
serial=${ADB_SERIAL}
else
devices=$("${adb_bin}" devices | awk '$2 == "device" {print $1}')
device_count=$(printf '%s\n' "${devices}" | sed '/^$/d' | wc -l | tr -d ' ')
if [[ "${device_count}" == 0 ]]; then
echo "No authorized Android device found. Connect one or set ADB_SERIAL." >&2
exit 2
fi
if [[ "${device_count}" != 1 ]]; then
echo "Multiple Android devices found; set ADB_SERIAL explicitly." >&2
printf '%s\n' "${devices}" >&2
exit 2
fi
serial=${devices}
fi
"${adb_bin}" -s "${serial}" install -r --no-incremental "${apk}"
installed_path=$("${adb_bin}" -s "${serial}" shell pm path com.droiddeck.launcher | tr -d '\r')
printf 'Installed on %s: %s\n' "${serial}" "${installed_path}"