Hello,
Using a Bourne shell script I would like my if statement to work if the variable's value is upper or lower case "Y". What would be the syntax for this?
Note - this did not work for me: if [ $DELETE = "[Yy]" ]; then
Thanks,
Michael42
Using a Bourne shell script I would like my if statement to work if the variable's value is upper or lower case "Y". What would be the syntax for this?
Note - this did not work for me: if [ $DELETE = "[Yy]" ]; then
Code:
DELETE="Y"
if [ $DELETE = "Y" ]; then
echo "Deleting stuff..."
fi
Thanks,
Michael42