summaryrefslogtreecommitdiffhomepage
path: root/linux
diff options
context:
space:
mode:
Diffstat (limited to 'linux')
-rw-r--r--linux/uninstall_script.sh16
1 files changed, 11 insertions, 5 deletions
diff --git a/linux/uninstall_script.sh b/linux/uninstall_script.sh
index d4565bcae2..b4f4671b92 100644
--- a/linux/uninstall_script.sh
+++ b/linux/uninstall_script.sh
@@ -1,17 +1,23 @@
#!/usr/bin/env bash
set -eu
+
function remove_systemd_unit {
- systemctl stop mullvad-daemon.service
- systemctl disable mullvad-daemon.service
+ systemctl stop mullvad-daemon.service || \
+ echo "Failed to stop mullvad-daemon service"
+ systemctl disable mullvad-daemon.service || \
+ echo "Failed to disable mullvad-daemon service"
}
function remove_logs_and_cache {
- rm -rf /var/log/mullvad-daemon/
- rm -rf /var/cache/mullvad-daemon/
+ rm -rf /var/log/mullvad-daemon/ || \
+ echo "Failed to remove mullvad-daemon logs"
+ rm -rf /var/cache/mullvad-daemon/ || \
+ echo "Failed to remove mullvad-daemon cache"
}
function remove_config {
- rm -rf /etc/mullvad-daemon
+ rm -rf /etc/mullvad-daemon || \
+ echo "Failed to remove mullvad-daemon config"
}
# checking what kind of an action is taking place