vpnhide/scripts/clean-device.sh
okhsunrog 6590c8344f Fix zygisk first-launch race: dashboard waited on stale selfNeedsRestart
ensureSelfInTargets() and loadDashboardState() ran as independent
coroutines, so the dashboard could read selfNeedsRestart=false before
the init completed. On slower devices (Pixel 4a) this caused "Installed,
inactive" instead of the restart prompt.

- Make selfNeedsRestart nullable; show spinner until resolved
- Sync zygisk targets to module dir so next app fork picks them up
- Show "restart app to activate" instead of misleading "inactive"
- Add scripts/clean-device.sh for testing fresh installs via adb
2026-04-14 15:24:20 +03:00

16 lines
645 B
Bash
Executable file

#!/usr/bin/env bash
# Wipe all VPN Hide data from a connected device for clean install testing.
# Usage: ./scripts/clean-device.sh
set -euo pipefail
echo "Uninstalling app..."
adb shell pm uninstall dev.okhsunrog.vpnhide 2>/dev/null || true
echo "Removing persistent data..."
adb shell su -c "rm -rf /data/adb/vpnhide_kmod /data/adb/vpnhide_zygisk /data/adb/vpnhide_lsposed" 2>/dev/null || true
echo "Removing runtime files..."
adb shell su -c "rm -f /data/system/vpnhide_uids.txt" 2>/dev/null || true
adb shell su -c "rm -rf /data/user/0/dev.okhsunrog.vpnhide" 2>/dev/null || true
echo "Done. Reboot recommended if modules were installed."