1
votes

After sbt run, a project I'm working on is showing some errors/warnings, and seems to pause.

How do I quit sbt from here?

If I press ctrl+z or ctrl+c, it stops, but the next time I run sbt it says:

[warn] sbt server could not start because there's another instance of sbt running on this build.

Running multiple instances is unsupported

So how do I (force?) quit correctly after sbt run?

2

2 Answers

3
votes

In build.sbt:

fork in run := true
1
votes

Since the comments on the accepted answer say it didn't work for you I'll offer another workaround.

You can always kill running instances of sbt server by looking for java processes (SBT runs within the JVM) and killing them.

pgrep -a java to list PIDs of all java processes.

kill -9 {PID} to kill a process by PID.

Or just open Activity Monitor/Resource Monitor and kill process with Process Name "java".