SBT 停止运行而不退出 [英] SBT stop run without exiting

查看:53
本文介绍了SBT 停止运行而不退出的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在不退出的情况下终止 SBT 中的运行?

How do you terminate a run in SBT without exiting?

我正在尝试 CTRL+C 但它退出了 SBT.有没有办法只退出正在运行的应用程序,同时保持 SBT 打开?

I'm trying CTRL+C but it exits SBT. Is there a way to only exit the running application while keeping SBT open?

推荐答案

在默认配置中,你的运行发生在 sbt 正在运行的同一个 JVM 中,所以你不能轻易地单独杀死它们.

In the default configuration, your runs happen in the same JVM that sbt is running, so you can't easily kill them separately.

如果您在单独的分叉 JVM 中运行,如 分叉,然后你可以在不影响sbt的JVM的情况下杀死那个JVM(通过你的操作系统提供的任何方式):

If you do your run in a separate, forked JVM, as described at Forking, then you can kill that JVM (by any means your operating system offers) without affecting sbt's JVM:

fork in run := true

这篇关于SBT 停止运行而不退出的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆