mirror of https://github.com/sbt/sbt.git
Fix actions/join test
This commit is contained in:
parent
b92b2c7109
commit
4b154cbe7a
|
|
@ -0,0 +1,20 @@
|
|||
lazy val intTask = taskKey[Int]("int")
|
||||
|
||||
lazy val root = (project in file(".")).
|
||||
dependsOn(b, c).
|
||||
settings(
|
||||
intTask in Compile := {
|
||||
// a sequence of tasks could be joined together
|
||||
Seq(b, c).map(p => intTask in (p, Compile)).join.map( as => (1 /: as)(_ + _) ).value
|
||||
}
|
||||
)
|
||||
|
||||
lazy val b = (project in file("b")).
|
||||
settings(
|
||||
intTask in Compile := 1
|
||||
)
|
||||
|
||||
lazy val c = (project in file("c")).
|
||||
settings{
|
||||
intTask in Compile := 2
|
||||
}
|
||||
|
|
@ -1,12 +0,0 @@
|
|||
import sbt._
|
||||
import Keys._
|
||||
import Import._
|
||||
|
||||
object Build extends Build
|
||||
{
|
||||
lazy val root = Project("root", file(".")) dependsOn(b,c) settings(
|
||||
compile in Compile <<= Seq(b, c).map(p => compile in (p, Compile)).join.map( as => (inc.Analysis.Empty /: as)(_ ++ _) )
|
||||
)
|
||||
lazy val b = Project("b", file("b"))
|
||||
lazy val c = Project("c", file("c"))
|
||||
}
|
||||
Loading…
Reference in New Issue