Launch Scala REPL within console application

My project env doesn’t have access to bin/scala. But I have classes like

scala.tools.nsc.interactive.REPL

On my classpath. Is there a way I can launch REPL as main class to give the right experience?

I want to know how we get from

$ scala

to

Starting scala REPL...
scala> val a = 10

Take a look at Ammonite.

1 Like

Managed to do some digging and realized this is what I wanted:

bin/java scala.tools.nsc.MainGenericRunner