scala - sbt-android: IntelliJ marks usages of android support resources red -
i using sbt-android plugin develop android applications scala , sbt.
i have written little project sample code, runs great.
but intellij marks "pointers" library resources red - can define them, not use them.
it says, e.g. : 'cannot find symbol theme.appcompat'.
here pictures:
here build.sbt:
name := "scalandroid" import android.keys._ import android.dependencies.{apklib,aar} androidbuild javacoptions ++= seq("-source", "1.7", "-target", "1.7") scalaversion := "2.11.7" resolvers += "bugsense repository" @ "http://www.bugsense.com/gradle/" librarydependencies ++= seq( aar("com.android.support" % "appcompat-v7" % "24.2.0"), aar("com.android.support" % "cardview-v7" % "24.2.0"), aar("com.android.support" % "support-v4" % "24.2.0"), aar("com.android.support" % "design" % "24.2.0"), aar("com.android.support" % "recyclerview-v7" % "24.2.0") ) scalacoptions in compile += "-feature" compileorder := compileorder.javathenscala compileorder in android := compileorder.javathenscala proguardoptions in android ++= seq("-dontobfuscate", "-dontoptimize", "- keepattributes signature", "-printseeds target/seeds.txt", "- printusage target/usage.txt" , "-dontwarn scala.collection.**" // required scala 2.11.4 ) run <<= run in android install <<= install in android proguardscala in android := true useproguard in android := true // tests ////////////////////////////// librarydependencies ++= seq( "org.apache.maven" % "maven-ant-tasks" % "2.1.3" % "test", "org.robolectric" % "robolectric" % "3.0" % "test", "junit" % "junit" % "4.12" % "test", "com.novocode" % "junit-interface" % "0.11" % "test" ) // without this, @config throws exception, unmanagedclasspath in test ++= (bootclasspath in android).value
and here project/plugins.sbt:
addsbtplugin("org.scala-android" % "sbt-android" % "1.6.16") addsbtplugin("org.scala-android" % "sbt-android-protify" % "1.3.2") librarydependencies += "net.sf.proguard" % "proguard-base" % "5.2.1"
it known issue in intellij
you can either switch nightly scala plugin in idea or download file , replace local copy
Comments
Post a Comment