From 7690d756c021eb7cbce2acc98e80da28aebd888d Mon Sep 17 00:00:00 2001 From: PierreGoude Date: Wed, 21 Mar 2018 10:57:23 +0100 Subject: [PATCH] Update ADconnection.sh --- ADconnection.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ADconnection.sh b/ADconnection.sh index 2c4be7b..d327cec 100644 --- a/ADconnection.sh +++ b/ADconnection.sh @@ -995,7 +995,9 @@ LEFT=$(sudo realm discover | grep configured | awk '{print $2}') DOMAIN=$(realm discover | grep -i realm.name | awk '{print $2}') if [ "$LEFT" = "no" ] then + echo "" echo "$DOMAIN has not been configured" + echo "" exit fi read -p "Do you really want to leave the domain: $DOMAIN (y/n)?" yn @@ -1003,6 +1005,7 @@ read -p "Do you really want to leave the domain: $DOMAIN (y/n)?" yn [Yy]* ) echo "Listing domain" sudo realm discover $DOMAIN sudo realm leave $DOMAIN + LEFT=$(sudo realm discover | grep configured | awk '{print $2}') if [ "$LEFT" = "no" ] then echo ""