diff --git a/build.sh b/build.sh index 3d38b5d..befc53e 100755 --- a/build.sh +++ b/build.sh @@ -38,7 +38,17 @@ read -p "IMAP Port (default: 993 for SSL, 143 for STARTTLS): " IMAP_PORT IMAP_PORT=${IMAP_PORT:-993} read -p "IMAP Username: " IMAP_USER +if [ -z "$IMAP_USER" ]; then + echo "❌ Error: IMAP username cannot be empty" + exit 1 +fi + read -sp "IMAP Password: " IMAP_PASS +if [ -z "$IMAP_PASS" ]; then + echo "❌ Error: IMAP password cannot be empty" + exit 1 +fi + echo "" read -p "SMTP Server hostname (default: teamworkapps.com): " SMTP_SERVER @@ -51,12 +61,15 @@ read -p "SMTP Username (default: same as IMAP): " SMTP_USER SMTP_USER=${SMTP_USER:-$IMAP_USER} read -sp "SMTP Password (default: same as IMAP): " SMTP_PASS -echo "" - if [ -z "$SMTP_PASS" ]; then SMTP_PASS="$IMAP_PASS" fi +if [ -z "$SMTP_PASS" ]; then + echo "❌ Error: SMTP password cannot be empty (IMAP password also empty)" + exit 1 +fi + read -p "Use SSL/TLS? (Y/n, default: Y): " USE_SSL USE_SSL=${USE_SSL:-Y}