title: Bash: Convert string to lowercase AND store changes in updated variable
body: <p>In my bash script, I want to take the response and make it lower case to anticipate and avoid errors.</p>
  <p>However, when I convert to my <code>response</code> to lower case, I can't seem to store that change in the variable.</p>
  <p>How can I update the case of an input string and store such that I can compare it later?</p>
  <pre><code>#!/usr/bin/env bash -e
  
  
  echo &quot;To reset cluster on existing EKS cluster, we must first destroy the existing cluster.&quot;
  read -p &quot;Do you want to auto-approve the terraform destroy (y/n): &quot; response
  
  response=&quot;$response&quot; | tr '[:upper:]' '[:lower:]'
  
  echo $response
  
  if [ $response = 'y' ]; then
      echo &quot;Destroy is auto-approved.&quot;
  else 
      echo &quot;Destroy is not auto-approved&quot;
  fi
  </code></pre>