how to make case insensitive checks????

Hi,

I have tried to make the conditions similar to the below one's, perhaps, I am not sure if there are any more way's to do that????


if [[ $x = +([HELLO|hello]) ]]

echo "Whatever"
fi

See if this works for you:

typeset -l varlowercase
if [ "${varlowercase}" = "hello" ]; then
  echo "Found"
fi

does that mean any value that has been assigned will be converted to lower case????
of instance would it be

typeset -l var
var="HELLO"
echo $var
hello

and also, do any one of you know any good refrence material for regular expressions?????

Yes, the declaration:
typeset -l varlowercase
means a variable lowercase is being declared and
every combination of letters assigned to it will be
stored in lower case.

Thanks Shell Life

Sorry Duplicate post