title: Check if a string matches a regex in Bash script
body: <p>One of the arguments that my script receives is a date in the following format: <code>yyyymmdd</code>.</p>
  
  <p>I want to check if I get a valid date as an input.</p>
  
  <p>How can I do this? I am trying to use a regex like: <code>[0-9]\{\8}</code></p>