title: Bash convention for if ; then
body: <p>From this web page :</p>
  
  <p><a href="http://tldp.org/LDP/abs/html/abs-guide.html">http://tldp.org/LDP/abs/html/abs-guide.html</a></p>
  
  <p>It's mentioned the usage of the if bracket then convention which need a space after the semicolon :</p>
  
  <blockquote>
    <p>;</p>
  
  <pre><code>Command separator [semicolon]. Permits putting two or more commands on the same line.
  
  echo hello; echo there
  
  
  if [ -x "$filename" ]; then    #  Note the space after the semicolon.
  #+                   ^^
    echo "File $filename exists."; cp $filename $filename.bak
  else   #                       ^^
    echo "File $filename not found."; touch $filename
  fi; echo "File test complete."
  
  Note that the ";" sometimes needs to be escaped.
  </code></pre>
  </blockquote>
  
  <p>Does anyone know where is this coming from and if this is needed at all by certain shells?</p>