⬅︎ Back to Read in passwords with bash
Before doing a "stty -echo" or a "read -s", you should set trapping like so:trap "stty echo; exit" INT TERM EXITOtherwise the script can exit in a state where the user can't see there keystrokes and then they get confused.
Comment
Before doing a "stty -echo" or a "read -s", you should set trapping like so:
trap "stty echo; exit" INT TERM EXIT
Otherwise the script can exit in a state where the user can't see there keystrokes and then they get confused.