Fix Dotty plugin test

Ref https://github.com/sbt/sbt/pull/4084
This commit is contained in:
Eugene Yokota 2018-05-05 15:19:47 -04:00
parent d8fe09f007
commit 2b099c86b5
2 changed files with 15 additions and 18 deletions

View File

@ -1,19 +1,16 @@
lazy val dottyVersion = dottyLatestNightlyBuild
// hardcode dottyVersion to make test deterministic
lazy val dottyVersion = "0.8.0-bin-20180424-e77604d-NIGHTLY"
lazy val pluginSetting = Seq(
name := "dividezero",
version := "0.0.1",
organization := "ch.epfl.lamp",
scalaVersion := dottyVersion,
libraryDependencies ++= Seq(
"ch.epfl.lamp" %% "dotty" % "provided"
lazy val plugin = (project in file("plugin"))
.settings(
name := "dividezero",
version := "0.0.1",
organization := "ch.epfl.lamp",
scalaVersion := dottyVersion,
)
)
lazy val plugin = (project in file("plugin")).settings(pluginSetting: _*)
lazy val app = (project in file(".")).settings(
scalaVersion := dottyVersion,
libraryDependencies += compilerPlugin("ch.epfl.lamp" %% "dividezero" % "0.0.1")
)
lazy val app = (project in file("."))
.settings(
scalaVersion := dottyVersion,
libraryDependencies += compilerPlugin("ch.epfl.lamp" %% "dividezero" % "0.0.1"),
)

View File

@ -18,8 +18,8 @@ class DivideZero extends PluginPhase with StandardPlugin {
val phaseName = name
override val runsAfter = Set(Pickler.phaseName)
override val runsBefore = Set(LinkAll.phaseName)
override val runsAfter = Set(Pickler.name)
override val runsBefore = Set(LinkAll.name)
override def init(options: List[String]): List[PluginPhase] = this :: Nil