title: zsh: parse error: condition expected: "$1"
body: <p>I tried to write a script to compile java files with gentoos java-config but i ended up getting an error 
  zsh: parse error: condition expected: "$1" Can anyone tell me what this means and why it gets reported at line 16 in the function. </p>
  
  <pre><code>function jComp() {
  
  local java_mods = ""
  
  if (( $# == 0)); then
    echo "using javac on .java in folder"
    `javac *.java`
    return 0
  
  elif [[ "$1" == "-h" ]] || [[ "$1" == "--help" ]]; then
    echo "Usage: jComp [java modules] [file]"
    echo
    echo "Options:"
    echo "    -h,   This help message."
    echo "modules has to be in the (java-config -l) list" 
    echo
    echo "Report bugs to &lt;tellone.diloom@gmail.com&gt;."
  
    return 0
  fi
  
  if [[ "$(java-config -v)" == "" ]]; then
    echo "This script depends on java-config"
    return 1
  elif [[ "$1" =="-d" ]] || [[ "$1" == "--default"]]; then
   `javac -cp .:$(java-config -p junit-4) *.java`
    if [[ $# == 2 ]]; then
      `javac -c .:$(java-config -p junit-4) "$2"`
       return 0
    fi
  fi
  
  
  while (( $# &gt; 1 )); do
  if [[ ! -f "$1" ]]; then
      java_mods="$java_mods $1"
      shift
      continue
  fi
  done
  
  `javac -cp .:$(java-config $java_mods)`
  
  return 0
  }
  </code></pre>
  
  <p>Links and comment are welcome. Thanks in advance</p>