title: Bash: How to compare arguments with if statement?
body: <p>I'm trying to compare an argument in bash under OSX using the following code...</p>
  
  <pre><code> #!/bin/bash
  
  if ["$1" == "1"]
  then
          echo $1
  else
          echo "no"
  fi
  </code></pre>
  
  <p>But I keep getting the following error </p>
  
  <pre><code>$bash script.sh 1
  
  script.sh: line 3: [1: command not found
  no
  </code></pre>
  
  <p>How do I stop it from trying to evaluate "1"?</p>