Adjust actions/task-map

This commit is contained in:
Eugene Yokota 2017-04-04 19:12:00 -04:00
parent c9ba9502a7
commit 690f1c4470
2 changed files with 2 additions and 22 deletions

View File

@ -1,38 +1,26 @@
val taskA = taskKey[File]("")
val taskB = taskKey[File]("")
val taskC = taskKey[File]("")
val taskD = taskKey[File]("")
val taskE = taskKey[File]("")
val taskF = taskKey[File]("")
val taskG = taskKey[File]("")
val taskH = taskKey[File]("")
taskA := touch(target.value / "a")
taskB := touch(target.value / "b")
taskC := touch(target.value / "c")
taskD := touch(target.value / "d")
taskE := touch(target.value / "e")
taskF := touch(target.value / "f")
taskG := touch(target.value / "g")
taskH := touch(target.value / "h")
// a <<= a triggeredBy b
// means "a" will be triggered by "b"
// said differently, invoking "b" will run "b" and then run "a"
taskA <<= taskA triggeredBy taskB
taskC := (taskC triggeredBy taskD).value
taskA := (taskA triggeredBy taskB).value
// e <<= e runBefore f
// means "e" will be run before running "f"
// said differently, invoking "f" will run "e" and then run "f"
taskE <<= taskE runBefore taskF
taskG := (taskG runBefore taskH).value
taskE := (taskE runBefore taskF).value
// test utils
def touch(f: File): File = { IO touch f; f }

View File

@ -2,14 +2,6 @@
$ exists target/b
$ exists target/a
> taskD
$ exists target/d
$ exists target/c
> taskF
$ exists target/e
$ exists target/f
> taskH
$ exists target/g
$ exists target/h