I have an if/then statement prompting for user input:
if [[ "$email_answer" = [Yy] ]]; then
How do I get that statement to accept the word "Yes", "YES" or "yes" in addition to "Y" or "y"?
I have an if/then statement prompting for user input:
if [[ "$email_answer" = [Yy] ]]; then
How do I get that statement to accept the word "Yes", "YES" or "yes" in addition to "Y" or "y"?
You can use case
for this:
case $email_answer in
[yY][eE][sS]|[yY])
;;
esac