I use IntelliJ Idea 14 Ultimate.
I have a multimodule project with a project/Build.scala
. Here is the layout of my project.
- myproject
- module 1
- module 2
- project
- Build.scala
I try to use the native SBT from scala plugin. I choose Import project from external model and then select SBT. Then I select the root folder of my project and click on Finish.
But the project is not well imported. Libraries are downloaded but all imports are in red in submodules (cannot resolve).
So I have to use sbt gen-idea, that works fine, but I would be very happy to get rid of it …
Launch IntelliJ IDEA. If the Welcome screen opens, press Ctrl+Shift+A , type project from existing sources , and click the Import project from existing sources action in the popup. Otherwise, from the main menu, select File | New | Project from Existing Sources.
The sbt tool window is enabled automatically when you create or open your sbt project. Click sbt on the right sidebar to open the tool window. The tool window displays the sbt linked projects, their tasks, dependencies, and all changes made to the underlying build.
Library dependencies can be added in two ways: unmanaged dependencies are jars dropped into the lib directory. managed dependencies are configured in the build definition and downloaded automatically from repositories.
I had the same problem (IDEA 14 Ultimate). This solve that after import. File > Invalidate Caches / Restart... Shown here
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With