title: Are double square brackets [[ ]] preferable over single square brackets [ ] in Bash?
body: <p>A coworker claimed recently in a code review that the <code>[[ ]]</code> construct is to be preferred over <code>[ ]</code> in constructs like</p>
  <pre><code>if [ &quot;`id -nu`&quot; = &quot;$someuser&quot; ] ; then
       echo &quot;I love you madly, $someuser&quot;
  fi
  </code></pre>
  <p>He couldn't provide a rationale. Is there one?</p>