1

I have set an environment variable for the classpath:

~/spark-0.8.0-incubating-bin-hadoop1 >echo $CP
:/home/sboesch/spark-0.8.0-incubating-bin-hadoop1/conf:/home/sboesch/spark-0.8.0-incubating-bin-hadoop1/assembly/target/scala-2.9.3/spark-

However that is not visible for System.getProperty in the repl:

~/spark-0.8.0-incubating-bin-hadoop1 >scala -classpath $CP 
Welcome to Scala version 2.9.3 (Java HotSpot(TM) 64-Bit Server VM, Java 1.6.0_23).
Type in expressions to have them evaluated.
Type :help for more information.

scala> System.getProperty("java.class.path")                                                                                                                              
res0: java.lang.String = .
WestCoastProjects
  • 58,982
  • 91
  • 316
  • 560
  • 1
    It seems that the scala classpath differs from the java classpath : http://stackoverflow.com/questions/4121567/embedded-scala-repl-inherits-parent-classpath . Perhaps scala -cp sets only the scala-classpath. – Andreas Neumann Apr 23 '14 at 09:05
  • Any ideas how to set the internal java cp ? e.g. -J-cp $JAVA_CP – WestCoastProjects May 29 '14 at 16:54

0 Answers0