diff rlm/swank-all.pl @ 7:913acb5a675b

repaired old repl script using changes from dylan
author Robert McIntyre <rlm@mit.edu>
date Thu, 01 Mar 2012 06:28:39 -0700
parents e22ae14fa9d5
children 00524751595b
line wrap: on
line diff
     1.1 --- a/rlm/swank-all.pl	Thu Mar 01 05:45:14 2012 -0700
     1.2 +++ b/rlm/swank-all.pl	Thu Mar 01 06:28:39 2012 -0700
     1.3 @@ -1,5 +1,7 @@
     1.4  #!/usr/bin/perl
     1.5  
     1.6 +$replP =  $ARGV[0];
     1.7 +
     1.8  @JVM_options = 
     1.9    ("-verbose:gc",
    1.10     "-Xmn500M",
    1.11 @@ -76,16 +78,22 @@
    1.12  $classpath_libs = join ":", @classpath_libs;
    1.13  $C_libs = join ":", @C_libs;
    1.14  
    1.15 -$clojure_launch ="clojure.main";
    1.16 -$clojure_launch .= " -e ";
    1.17 -$clojure_launch .= '"';
    1.18 -$clojure_launch .= "(do (require 'swank.swank)";
    1.19 -$clojure_launch .= "(require 'rlm.rlm-commands)";
    1.20 -$clojure_launch .= "(swank.swank/start-repl 4005))";
    1.21 -$clojure_launch .= '"';
    1.22 +$swank_launch ="clojure.main";
    1.23 +$swank_launch .= " -e ";
    1.24 +$swank_launch .= '"';
    1.25 +$swank_launch .= "(do (require 'swank.swank)";
    1.26 +$swank_launch .= "(require 'rlm.rlm-commands)";
    1.27 +$swank_launch .= "(swank.swank/start-repl 4005))";
    1.28 +$swank_launch .= '"';
    1.29  
    1.30 -$command = "java ".$JVM_options." -cp ".$classpath_projects.":".$classpath_libs
    1.31 -  ." -Djava.library.path=".$C_libs." ".$clojure_launch;
    1.32 +$repl_launch = "clojure.main";
    1.33 +
    1.34 +$clojure_command = $swank_launch;
    1.35 +
    1.36 +if ($replP eq "--repl") {$clojure_command = $repl_launch;}
    1.37 +
    1.38 +$command = "java $JVM_options -cp $classpath_projects:$classpath_libs" .
    1.39 +    " -Djava.library.path=$C_libs $clojure_command";
    1.40  
    1.41  print "$command\n";
    1.42