From: Colin P. Mccabe Date: Fri, 4 Aug 2017 23:31:57 +0000 (-0700) Subject: dec.sh: add password prompt X-Git-Url: http://club.cc.cmu.edu/~cmccabe/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f5049e9ec9a5fe1a98663174bc659b56a6871e95;p=cmccabe-bin dec.sh: add password prompt --- diff --git a/dec.sh b/dec.sh index bbad6c6..d5c2709 100755 --- a/dec.sh +++ b/dec.sh @@ -5,7 +5,9 @@ die() { exit 1 } -[ "x${PASS}" = "x" ] && die "you must set PASS to the password" +if [[ "x${PASS}" = "x" ]]; then + read -s -p "enter password: " PASS +fi RET=0 for FILE in "$@"; do