From 018c43cdc4a98b4d3ef612009108fa0dc0f6eaab Mon Sep 17 00:00:00 2001 From: pucherot Date: Sun, 11 Apr 2021 11:47:39 +0200 Subject: [PATCH] Update pialert_uninstall.sh --- install/pialert_uninstall.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/install/pialert_uninstall.sh b/install/pialert_uninstall.sh index 104b12e6..46d520d9 100644 --- a/install/pialert_uninstall.sh +++ b/install/pialert_uninstall.sh @@ -49,9 +49,11 @@ main() { # Removing print_header "Removing Pi.Alert DNS name" + if [ -f /etc/pihole/custom.list ] ; then # sudo sed -i '/pi.alert/d' /etc/pihole/custom.list 2>&1 >> "$LOG" # sudo pihole restartdns 2>&1 >> "$LOG" - + fi + # Uninstall crontab jobs print_header "Removing crontab jobs" # crontab -l 2>/dev/null | sed '/pialert.py/d' | sed ':a;N;$!ba;s/#-------------------------------------------------------------------------------\n# Pi.Alert\n# Open Source Network Guard \/ WIFI & LAN intrusion detector \n#\n# pialert.cron - Back module. Crontab jobs\n#-------------------------------------------------------------------------------\n# Puche 2021 pi.alert.application@gmail.com GNU GPLv3\n#-------------------------------------------------------------------------------//g' | crontab -