title: How to run the jar made from 'lein jar' command?
body: <p>This is a follow-up for <a href="https://stackoverflow.com/questions/3390268/how-to-setup-the-classpath-when-running-the-jar-made-from-lein-uberjar">this question</a>. </p>
  
  <p>After running 'lein jar', I get 'myproject-1.0.0-SNAPSHOT.jar', which doesn't contain the clojure-1.2.0-beta1.jar and clojure-contrib-1.2.0-beta1.jar. </p>
  
  <p>And running 'lein uberjar' gives me two jar files. The first one (that ends with -standalone.jar) is the jar contains everything, and the second one is the same as the jar generated with 'lein jar'. </p>
  
  <p>This is the question of the jar with the second one. There's no problem running with the first jar, as I explained in the previous <a href="https://stackoverflow.com/questions/3390268/how-to-setup-the-classpath-when-running-the-jar-made-from-lein-uberjar">post</a>. </p>
  
  <p>When I run</p>
  
  <pre>
  java -cp PATH_TO_THE_CLOJURE_AND_CONTRIB.jar:$CLASSPATH -jar myproject-1.0.0-SNAPSHOT.jar'
  </pre>
  
  <p>, I get the following error.</p>
  
  <pre>
  Caused by: java.lang.ClassNotFoundException: clojure.lang.IFn
          at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
          at java.security.AccessController.doPrivileged(Native Method)
          at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
          at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
          at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
          at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
  </pre>
  
  <p>What might be wrong, I thought I can use the 'myproject-1.0.0-SNAPSHOT.jar the same way with 'myproject-1.0.0-SNAPSHOT-standalone.jar' if I point to the jar files using -cp option.</p>
  
  <p>Is there anything more that I had to do?</p>
  
  <h2>ADDED</h2>
  
  <pre>
  java -cp ALLTHE_JAR_PATH myproject.core
  </pre>
  
  <p>solves the problem.</p>