All Downloads are FREE. Search and download functionalities are using the official Maven repository.

mill.scalalib.CrossSbtModule.scala Maven / Gradle / Ivy

There is a newer version: 0.12.0-RC2-17-07e173
Show newest version
package mill.scalalib

import mill.api.PathRef
import mill.T
import mill.scalalib.{CrossModuleBase, SbtModule}

trait CrossSbtModule extends SbtModule with CrossModuleBase { outer =>

  override def sources: T[Seq[PathRef]] = T.sources {
    super.sources() ++ scalaVersionDirectoryNames.map(s =>
      PathRef(millSourcePath / "src" / "main" / s"scala-$s")
    )
  }

  type CrossSbtTests = CrossSbtModuleTests
  @deprecated("Use CrossSbtTests instead", since = "Mill 0.11.10")
  trait CrossSbtModuleTests extends SbtModuleTests {
    override def millSourcePath = outer.millSourcePath
    override def sources = T.sources {
      super.sources() ++ scalaVersionDirectoryNames.map(s =>
        PathRef(millSourcePath / "src" / "test" / s"scala-$s")
      )
    }
  }
  trait Tests extends CrossSbtModuleTests
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy