title: SBT compilation for play framework 2.x disabled by default
body: <p>I created a new Play Framework project using the activator, <code>activator new my-project-name</code> and  then I selected the <code>play-java</code> template and the project is created with no errors.</p>
  
  <p>Then I import the project into my IDE, IntelliJ, as a SBT project. When the project is imported a popup is shown saying: <code>SBT compilation for play framework 2.x disabled by default</code>.</p>
  
  <p>On IntelliJ project's panel it doesn't show all (mostly the files with the code) files. Just a handful of them.</p>
  
  <p><a href="https://i.stack.imgur.com/LRvz5.png"><img src="https://i.stack.imgur.com/LRvz5.png" alt="enter image description here"></a></p>
  
  <p>The build.sbt file looks like full of compilation error (pretty much all the lines are red underlined).</p>
  
  <p>Here's the build.sbt file</p>
  
  <pre><code>name := """my-project-name"""
  
  version := "1.0-SNAPSHOT"
  
  lazy val root = (project in file(".")).enablePlugins(PlayJava)
  
  scalaVersion := "2.11.6"
  
  libraryDependencies ++= Seq(
    javaJdbc,
    cache,
    javaWs
  )
  
  // Play provides two styles of routers, one expects its actions to be injected, the
  // other, legacy style, accesses its actions statically.
  routesGenerator := InjectedRoutesGenerator
  
  
  fork in run := true
  </code></pre>
  
  <p>I can compile and run the code with <code>activator ui</code> with no errors. So, why isn't IntelliJ fully importing the project and it shows me <code>SBT compilation for play framework 2.x disabled by default</code> message?</p>
  
  <p>I googled around and couldn't find any hint related to this so I'm kinda lost here. </p>
  
  <p><strong>EDIT: -------------------------------------</strong></p>
  
  <p>I closed the project on IntelliJ and deleted the project folder. Closed IntelliJ and using <code>activator</code> I created again the same project. Using <code>activator ui</code> I compiled the project. Then I fired up IntelliJ and was prompted to either open a project, create a new one or import a project.</p>
  
  <p>Selected import a project and did the normal "import a project steps" and IntelliJ imported the project with no hassle. <strong>But</strong> if I try to import the project while with an open project on IntelliJ I get the same problem that lead me to make this question. Maybe this is a bug on IntelliJ?</p>
  
  <p><strong>EDIT 2 ------------------------------------------</strong></p>
  
  <p>The solution to these two problems (the "<em>SBT compilation for play framework 2.x disabled by default</em>" and the files not showing on IntelliJ) can be fixed with <code>user3384225</code> and <code>DarkShadow</code> answers.</p>