sbt-intellij and generated code
Hi,
I'm using scalaxb to generate some code from xsd/wsdl. This is put in target/scala-2.10/source_managed. I'm using the new sbt-plugin to import sbt-projects in IntelliJ Idea: http://blog.jetbrains.com/scala/2013/07/17/sbt-plugin-nightly-builds/ The problem I have is that the generated code is not recognized and therefore I get compile errors in the IDE only.
In my build.sbt I added this to fix it for sbt-eclipse:
// https://groups.google.com/forum/?fromgroups#!searchin/simple-build-tool/sbteclipse/simple-build-tool/9gkClewLcVY/ggat4xmFicYJ
EclipseKeys.createSrc := EclipseCreateSrc.ValueSet(EclipseCreateSrc.Source, EclipseCreateSrc.Resource, EclipseCreateSrc.Unmanaged, EclipseCreateSrc.Managed)
Is there anything I can do to add the source_managed directory to sources in Idea? I'm kindof new to this IDE :)
Cheers,
Viktor
Please sign in to leave a comment.
Just realized that I don't understand what's going on. Isn't the build supposed to be external? I mean, that folder in target is of course part of sources in Compile in the sbt build - it builds cmd line. Does Idea provide sbt with other settings when running make?
Anyway, I found the way to add it as a source folder in the project structure and now it builds. Would be nicer if the plugin automatically took all the source folders from the sbt build definition though.
Thanks,
Viktor
We've fixed that. The next nightly build should correctly import managed source (and resource) directories.
Brilliant, thanks!
/Viktor