How to get rid of scalac ServerException with IntelliJ Idea

前端 未结 3 1170
后悔当初
后悔当初 2021-02-19 10:05

This error prevents me from running the project.

Here are versions info :

~ ❯❯❯ java -version
java version \"1.8.0_45\"
Java(TM) SE Runtime Environment (         


        
3条回答
  •  忘掉有多难
    2021-02-19 10:18

    Note that in scala-2.12, scala binary file is a wrapper script.

    It looks like your JAVA_HOME directory is not correctly set.

    Take a look at line that reads (inside $SCALA_HOME/bin/scala):

    java_release="$(cat $JAVA_HOME/release | grep JAVA_VERSION)"
    

    Based on your output, it looks like JAVA_HOME is not set. What you get is:

    cat: /release: No such file or directory
    

提交回复
热议问题