diff options
author | Christopher Vogt <oss.nsp@cvogt.org> | 2017-04-05 01:55:57 +0000 |
---|---|---|
committer | Christopher Vogt <oss.nsp@cvogt.org> | 2017-04-05 01:55:57 +0000 |
commit | e174d1db2b27a2a9018169cb0dc03635df8de11d (patch) | |
tree | e108813326ba21da8470e2d2fa2f6cddeb05d177 /stage2/plugins | |
parent | 439190b6bf46ccb971c0ec708da38d437f2e331d (diff) | |
download | cbt-e174d1db2b27a2a9018169cb0dc03635df8de11d.tar.gz cbt-e174d1db2b27a2a9018169cb0dc03635df8de11d.tar.bz2 cbt-e174d1db2b27a2a9018169cb0dc03635df8de11d.zip |
Add ScalaXRay (sxr) plugin
Diffstat (limited to 'stage2/plugins')
-rw-r--r-- | stage2/plugins/ScalaXRay.scala | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/stage2/plugins/ScalaXRay.scala b/stage2/plugins/ScalaXRay.scala new file mode 100644 index 0000000..9654c59 --- /dev/null +++ b/stage2/plugins/ScalaXRay.scala @@ -0,0 +1,17 @@ +package cbt +import java.io.File +trait ScalaXRay extends BaseBuild{ + override def scalacOptions = { + super.scalacOptions ++ ScalaXRay.scalacOptions( + ports.scalaXRay.dependency.asInstanceOf[PackageJars] + ) + } +} +object ScalaXRay{ + def scalacOptions( plugin: PackageJars, linkFile: Option[File] = None ) = + Seq( + "-Xplugin:" ~ plugin.jar.get.string, + "-Xplugin-require:sxr" + //"-P:sxr:base-directory:" ~ baseDirectory.string + ) ++ linkFile.map( "-P:sxr:link-file:" ~ _.string ) +} |