title: Why bash if =~ regex negate a character do not work
body: <pre><code>test="blah*blah"
  if ! [[ ${test} =~ [\*] ]] ; then echo ok; else echo failed; fi
  </code></pre>
  
  <p>=> failed</p>
  
  <pre><code>test="blah/blah"
  if ! [[ ${test} =~ [\*] ]] ; then echo ok; else echo failed; fi
  </code></pre>
  
  <p>=> ok</p>
  
  <pre><code>test="blah/blah"
  if [[ ${test} =~ [^\*] ]] ; then echo ok; else echo failed; fi
  </code></pre>
  
  <p>=> ok</p>
  
  <pre><code>test="blah*blah"
  if [[ ${test} =~ [^\*] ]] ; then echo ok; else echo failed; fi
  </code></pre>
  
  <p>=> ok ??? WHY ?</p>
  
  <p>What is the secret to use a negate pattern for a character somewhere in string ?</p>