<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -1,13 +1,9 @@
 #!/usr/bin/env ruby
 
-begin
-  require &quot;johnson&quot;
-rescue LoadError
-  require &quot;rubygems&quot;
-  require &quot;johnson&quot;
-end
+$:.unshift(File.expand_path(File.join(File.dirname(__FILE__), &quot;..&quot;, &quot;lib&quot;)))
 
 require &quot;readline&quot;
+require &quot;johnson&quot;
 
 RUNTIME = js = Johnson::Runtime.new
 RUNTIME.evaluate(Johnson::CLI::JS)
@@ -63,12 +59,16 @@ options.files_to_preload.each { |f| RUNTIME.load(f) }
 
 unless options.expressions.empty?
   options.expressions.each { |e| RUNTIME.evaluate(e, '-e') }
-  exit if !options.file_to_evaluate
+  exit if options.files_to_evaluate.empty?
 end
 
-if options.file_to_evaluate
+unless options.files_to_evaluate.empty?
   RUNTIME[:arguments] = options.arguments
-  RUNTIME.load(options.file_to_evaluate)
+  
+  options.files_to_evaluate.each do |file|
+    RUNTIME.load(file)
+  end
+  
   exit
 end
 </diff>
      <filename>bin/johnson</filename>
    </modified>
    <modified>
      <diff>@@ -27,4 +27,4 @@ function quit() {
 
 function version() {
   return Ruby.Johnson.VERSION;
-}
\ No newline at end of file
+}</diff>
      <filename>js/johnson/cli.js</filename>
    </modified>
    <modified>
      <diff>@@ -10,19 +10,26 @@ module Johnson #:nodoc:
       attr_reader :arguments
       attr_reader :expressions
       attr_reader :files_to_preload
-      attr_reader :file_to_evaluate
+      attr_reader :files_to_evaluate
       attr_reader :load_paths
       attr_reader :paths_to_require
     
       def initialize(*args)
-        argv = args.flatten
+        @arguments = []
         @expressions = []
         @load_paths = []
         @files_to_preload = []
         @paths_to_require = []
 
+        argv = args.flatten
+        
+        if index = argv.index(&quot;--&quot;)
+          @arguments = argv[(index+1)..-1]
+          argv = argv[0..index]
+        end
+
         parser = OptionParser.new do |parser|
-          parser.banner = &quot;Usage: johnson [options] [file.js] [-- jsargs]&quot;
+          parser.banner = &quot;Usage: johnson [options] [file.js...] [-- jsargs...]&quot;
           parser.version = Johnson::VERSION
 
           parser.on(&quot;-e [EXPRESSION]&quot;, &quot;Evaluate [EXPRESSION] and exit&quot;) do |expression|
@@ -53,9 +60,7 @@ module Johnson #:nodoc:
         end
         
         parser.parse!(argv)
-
-        @file_to_evaluate = argv.shift
-        @arguments = argv.dup
+        @files_to_evaluate = argv.dup
       end 
     end
   end</diff>
      <filename>lib/johnson/cli/options.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>40378adbc77124d63c46c308b8c8f8d013570f67</id>
    </parent>
  </parents>
  <author>
    <name>John Barnette</name>
    <email>jbarnette@gmail.com</email>
  </author>
  <url>http://github.com/jbarnette/johnson/commit/b38a1ab0f0f253fc1eb16b048d7edf85ccc91740</url>
  <id>b38a1ab0f0f253fc1eb16b048d7edf85ccc91740</id>
  <committed-date>2008-09-09T01:03:44-07:00</committed-date>
  <authored-date>2008-09-09T01:03:44-07:00</authored-date>
  <message>It's now possible to execute multiple JS files on the command-line.

  $ johnson foo.js bar.js # will evaluate both</message>
  <tree>0348de23e85be7f367d0e3efea6b106adcac0dbe</tree>
  <committer>
    <name>John Barnette</name>
    <email>jbarnette@gmail.com</email>
  </committer>
</commit>
