Plugin Documentation

Goals available for this plugin:

Goal Description
sbt-compiler:addManagedSources Add managed source root, if it is not already added.

Helper mojo.
Adds ${project.build.directory/src_managed} as compile source root even if it does not exist yet (it may be created later by source generators).
sbt-compiler:addScalaSources Add default Scala source roots, if they exist and are not already added.

Helper mojo.
Adds:
  • src/main/scala as compile source root
  • src/test/scala as test compile source root
sbt-compiler:compile Compile Scala and Java main sources.
sbt-compiler:help Display help information on sbt-compiler-maven-plugin.
Call mvn sbt-compiler:help -Ddetail=true -Dgoal=<goal-name> to display parameter details.
sbt-compiler:testCompile Compile Scala and Java test sources.

System Requirements

The following specifies the minimum requirements to run this Maven plugin:

Maven 2.2.1
JDK 1.6
Memory No minimum requirement.
Disk Space No minimum requirement.

Usage

You should specify the version in your project's plugin configuration:

<project>
  ...
  <build>
    <!-- To define the plugin version in your parent POM -->
    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>com.google.code.sbt-compiler-maven-plugin</groupId>
          <artifactId>sbt-compiler-maven-plugin</artifactId>
          <version>1.0.0-beta9</version>
        </plugin>
        ...
      </plugins>
    </pluginManagement>
    <!-- To use the plugin goals in your POM or parent POM -->
    <plugins>
      <plugin>
        <groupId>com.google.code.sbt-compiler-maven-plugin</groupId>
        <artifactId>sbt-compiler-maven-plugin</artifactId>
        <version>1.0.0-beta9</version>
      </plugin>
      ...
    </plugins>
  </build>
  ...
</project>

For more information, see "Guide to Configuring Plug-ins"