如何:在 IDE 外部调试 Scala 代码
我正在尝试使用 jEdit 作为编写 Scala 代码的主要编辑器。
除了 jEdit 之外,我还使用 Apache Builder 和 DTerm。这一切都运行良好,只是我真的不确定如何在大型 IDE 之外调试 Scala 应用程序?
是否有在 IDE 之外进行调试的推荐实践/工具?
I'm experimenting with using jEdit as my main editor for writing Scala code.
Along side jEdit I'm using Apache Buildr and DTerm. This all works well, except I'm really not sure how I would go about debugging Scala application outside of a large IDE?
Are there recommended practices/tools for debugging outside of an IDE?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
您可以从应用程序中的某个点运行解释器(又名 REPL),而不是使用调试器。您可以在此处找到详细说明
Rather than using a debugger, you could run the interpreter (aka REPL) from a point in your application. You can find detailed instructions here
我不确定您是否可以完全通过 CLI 进行调试。任何基于 Java 的调试工具都应该足够了。
这个SO问题提到jswat,它也有控制台模式。
它用于此博客条目和可以很容易地安装,如此处所示。
I am not sure you can debug entirely through the CLI. Any Java-based debug tool should be enough.
This SO question mentions jswat, which also has a console mode.
It is used in this blog entry and can be installed quite easily as illustrated here.
几年前就有一个关于 CLI Scala 调试器的堆栈溢出问题。我刚刚在 2 月份发布了一个新的答案,涉及一个名为
sdb
的新 CLI,它模仿jdb
行为,同时提供对 Scala 名称解析和其他改进的支持。有 Scala 命令行调试器吗?
来自的答案那个话题是
There was a stack overflow question from years ago about a CLI Scala debugger. I just posted a new answer to it back in February about a new CLI called
sdb
that mimicsjdb
behaviour while providing support for Scala name demangling and other improvements.Is there a Scala command-line debugger?
The answer from that topic was