Intellij scala code#
In the left gutter, set your breakpoints for the lines of code you want to debug. Open your Scala application in the editor. IntelliJ IDEA lets you debug your code using IntelliJ IDEA debugger or the sbt shell. The result of execution is displayed in sbt shell tool window. In the list that opens, select the run task that will run a main method. In the sbt projects tool window, click sbt Tasks node. If you don't want to delegate your builds and imports to sbt, you can still work in the sbt shell (click sbr shell on the status bar) and run sbt commands directly from it including running your application. This option is also available when you create or import an sbt project.) On the sbt settings page, under the sbt shell select the build option (required sbt 0.13.5+) and click OK to save the changes. If you want to delegate your builds and imports to sbt, in the sbt tool window, click the icon and select sbt Settings. You can run your application using the sbt shell that is a part of any sbt project. Run a Scala application using the sbt shell You can also click the icon on the main toolbar to run your application. Alternatively, in the left gutter of the editor, click the icon and select Run 'name'. Press Shift+F10 to execute the application.
Run a Scala application via Intellij IDEAĬreate or import a Scala project as you would normally create or import any other project in IntelliJ IDEA. You can run your Scala code through IntelliJ IDEA, use sbt shell, or use Scala worksheet for a quick code evaluation. To access the dialog, select Run | Edit Configurations from the main menu.
To adjust configuration settings when you perform running or debugging processes, use the Run/Debug Configurations dialog. IntelliJ IDEA also lets you run your Scala code with coverage and configure code coverage settings. IntelliJ IDEA lets you run, debug and test your Scala applications as you would normally do with any other applications in IntelliJ IDEA.