Ubuntu + scala REPL, Commands not typed on console

前端 未结 6 636
故里飘歌
故里飘歌 2021-02-05 00:46

I am using Ubuntu 18.04 + Scala 2.11.12 (OpenJDK 64-Bit Server VM, Java 1.8.0_162).

Once I open the scala shell, I am not able to see anything that I type. It gets typed

6条回答
  •  谎友^
    谎友^ (楼主)
    2021-02-05 01:34

    The following thing is working for me.

    1. Start sbt
    2. Open a scala console via sbt.

      ~$ sbt
          [info] Loading project definition from /home/abhay/project
          [info] Set current project to abhay (in build file:/home/abhay/)
          [warn] sbt server could not start because there's another instance of sbt running on this build.
          [warn] Running multiple instances is unsupported
          sbt:abhay> console
          [info] Starting scala interpreter...
          Welcome to Scala 2.12.4 (Java HotSpot(TM) 64-Bit Server VM, Java 1.8.0_161).
          Type in expressions for evaluation. Or try :help.
          scala> printf("Hello, Abhay!"); 
          Hello, Abhay!
          scala>
      

    This is working for me for now.

    I am pretty sure its some environment issue. Anyone else facing something similar?

    ~Abhay

提交回复
热议问题