<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -15,22 +15,33 @@ if ARGV.first == &quot;--version&quot;
   exit 0
 end
 
+# =============================
+# = Initialize the baser Jars =
+# =============================
+@jars = %w( 
+  jline.jar 
+  jna.jar 
+  clojure.jar 
+  clojure-contrib.jar 
+).map{|j| &quot;#{CLOJURE_HOME}/#{j}&quot;}
+
+# ========================
+# = Command line parsing =
+# ========================
 CMDLINE = OptionParser.new do |opts|
   opts.separator &quot;&quot;  
   opts.on(&quot;-i&quot;, &quot;--interactive&quot;, &quot;run a REPL&quot;) {@interactive = true}
+  opts.on(&quot;-cp&quot;, &quot;--classpath&quot;, &quot;add to the classpath&quot;) {|path| @jars += path.split(&quot;:&quot;)}
 end
 
 CMDLINE.parse!(ARGV)
-if ARGV.length &gt; 0 &amp;&amp; !@interactive
-  puts &quot;You must specify a file to run when in script mode&quot;
-  exit(1)
-end
 
-JARS = %w( jline jna clojure clojure-contrib )
-CLASSPATH = e_sh(JARS.map{|j| &quot;#{CLOJURE_HOME}/#{j}.jar&quot;}).join(&quot;:&quot;)
+@interactive = true if ARGV.empty? #default to a REPL
+
+CLASSPATH = e_sh(@jars).join(&quot;:&quot;)
 
 if @interactive
-  exec(&quot;java -cp #{CLASSPATH} jline.ConsoleRunner clojure.lang.Repl #{e_sh(ARGV).join(&quot; &quot;)}&quot;)
-else
-  exec(&quot;java -cp #{CLASSPATH} clojure.lang.Script #{e_sh(ARGV).join(&quot; &quot;)}&quot;)  
+  exec(&quot;java -server -Djava.ext.dirs=./jars -cp #{CLASSPATH} jline.ConsoleRunner clojure.lang.Repl #{e_sh(ARGV).join(&quot; &quot;)}&quot;)
+else         
+  exec(&quot;java -server -Djava.ext.dirs=./jars -cp #{CLASSPATH} clojure.lang.Script #{e_sh(ARGV).join(&quot; &quot;)}&quot;)  
 end
\ No newline at end of file</diff>
      <filename>Vendor/clj</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>6c01ae973b894097973b5e53208122efd92b04a3</id>
    </parent>
  </parents>
  <author>
    <name>Scott Fleckenstein</name>
    <email>nullstyle@gmail.com</email>
  </author>
  <url>http://github.com/nullstyle/clojure-tmbundle/commit/c7a8831ff460e9e293276452ea6461d375b9a302</url>
  <id>c7a8831ff460e9e293276452ea6461d375b9a302</id>
  <committed-date>2008-11-17T22:38:05-08:00</committed-date>
  <authored-date>2008-11-17T22:38:05-08:00</authored-date>
  <message>rework clj a little bit (add java.ext.dir and server flags)</message>
  <tree>028520c631c9ad9e79d008db53613668a171ca42</tree>
  <committer>
    <name>Scott Fleckenstein</name>
    <email>nullstyle@gmail.com</email>
  </committer>
</commit>
