title: Whitespaces in CLASSPATH
body: <p>I am working on a Windows PC and have cygwin on it!
  I have organized all my jars under a directory within a few directories!
  I am writing a <code>bash</code> script to set the <code>CLASSPATH</code> by iterating through the directory that is passed as a parameter as follows:</p>
  
  <pre><code>for JAR_FILE in `ls *.jar`
  do
      CLASSPATH="$DIRECTORY_TO_LOOK_FOR_JARS"/$JAR_FILE:$CLASSPATH
  done
  </code></pre>
  
  <p>Whenever there are spaces in the directory that is passed like <code>/cygdrive/c/Documents and Settings/user/My Jars</code> and I run <code>java -cp $CLASSPATH somepackage.someclass</code>, it throws an error stating that the class <code>and</code> is not found, because the CLASSPATH variable is getting split after <code>/cygdrive/c/Documents</code>.</p>
  
  <p>Can someone help me to solve this issue?</p>