-
Notifications
You must be signed in to change notification settings - Fork 0
/
clean-removal.sh
38 lines (27 loc) · 1.3 KB
/
clean-removal.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#!/bin/bash
# Waydroid and Weston Uninstallation Script for Ubuntu-based Systems
# This script will remove Waydroid, Weston, associated packages, and custom desktop files and configuration directories.
echo "Starting Waydroid and Weston uninstallation..."
# Stop and disable Waydroid service if running
sudo systemctl stop waydroid-container
sudo systemctl disable waydroid-container
# Remove Waydroid package and its dependencies
sudo apt purge -y waydroid
sudo apt autoremove -y
# Remove Weston package and its dependencies
sudo apt purge -y weston
sudo apt autoremove -y
# Delete user configuration and cache related to Waydroid
rm -rf ~/.config/waydroid
rm -rf ~/.local/share/waydroid
rm -rf ~/.cache/waydroid
# Remove custom .desktop files (e.g., launchers)
find ~/.local/share/applications -type f -name '*waydroid*.desktop' -exec rm -f {} \;
# Remove any system-wide .desktop files related to Waydroid (if present)
sudo find /usr/share/applications -type f -name '*waydroid*.desktop' -exec rm -f {} \;
# Clean up remaining Waydroid directories (safety check)
sudo rm -rf /var/lib/waydroid
sudo rm -rf /etc/waydroid
echo "Waydroid and related files have been successfully removed from your system."
# Final confirmation
echo "Uninstallation complete. It is recommended to restart your system to apply changes."