From 6aa6b7ab03eb41dd4abe315a01e13b28809b0266 Mon Sep 17 00:00:00 2001 From: Stanislas Lange Date: Fri, 31 Jul 2020 15:49:49 +0200 Subject: [PATCH] Fix uninstall for Debian & Ubuntu --- wireguard-install.sh | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/wireguard-install.sh b/wireguard-install.sh index cd8b91a..55f24df 100644 --- a/wireguard-install.sh +++ b/wireguard-install.sh @@ -289,14 +289,10 @@ function uninstallWg() { systemctl disable "wg-quick@$SERVER_WG_NIC" if [[ $OS == 'ubuntu' ]]; then - apt-get remove --purge -y wireguard qrencode + apt-get autoremove --purge -y wireguard qrencode add-apt-repository -y -r ppa:wireguard/wireguard - apt-get autoremove -y elif [[ $OS == 'debian' ]]; then - apt-get remove --purge -y wireguard qrencode - rm -f "/etc/apt/sources.list.d/unstable.list" - rm -f "/etc/apt/preferences.d/limit-unstable" - apt-get autoremove -y + apt-get autoremove --purge -y wireguard qrencode elif [[ $OS == 'fedora' ]]; then dnf remove -y wireguard-tools qrencode if [[ $VERSION_ID -lt 32 ]]; then