From f0dfa4d53d375f4e4741f2cbb28730e3609a89fa Mon Sep 17 00:00:00 2001 From: Rob Gill Date: Thu, 31 May 2018 13:43:49 +1000 Subject: [PATCH] Stickler-bot... Signed-Off-By: Rob Gill --- automated install/uninstall.sh | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/automated install/uninstall.sh b/automated install/uninstall.sh index 51e85946..b8797dbb 100755 --- a/automated install/uninstall.sh +++ b/automated install/uninstall.sh @@ -74,14 +74,13 @@ removeAndPurge() { # Purge dependencies echo "" for i in "${DEPS[@]}"; do - package_check ${i} > /dev/null - if [[ "$?" -eq 0 ]]; then + if package_check "${i}" > /dev/null; then while true; do read -rp " ${QST} Do you wish to remove ${COL_WHITE}${i}${COL_NC} from your system? [Y/N] " yn case ${yn} in [Yy]* ) echo -ne " ${INFO} Removing ${i}..."; - ${SUDO} ${PKG_REMOVE} "${i}" &> /dev/null; + ${SUDO} "${PKG_REMOVE} ${i}" &> /dev/null; echo -e "${OVER} ${INFO} Removed ${i}"; break;; [Nn]* ) echo -e " ${INFO} Skipped ${i}"; break;;