diff options
author | Christopher Vogt <oss.nsp@cvogt.org> | 2017-03-19 19:58:36 -0400 |
---|---|---|
committer | Christopher Vogt <oss.nsp@cvogt.org> | 2017-03-27 23:54:15 -0400 |
commit | 52adb81450955472fe4ecd011615b80f6289def6 (patch) | |
tree | fc1f4c1e75522c05c2a5c9ecee283c8a9ea09029 /stage2/BasicBuild.scala | |
parent | 0a6f67c70d5f878d3045bbac9b70f94859eb47d9 (diff) | |
download | cbt-52adb81450955472fe4ecd011615b80f6289def6.tar.gz cbt-52adb81450955472fe4ecd011615b80f6289def6.tar.bz2 cbt-52adb81450955472fe4ecd011615b80f6289def6.zip |
cache friendly equality for builds
Diffstat (limited to 'stage2/BasicBuild.scala')
-rw-r--r-- | stage2/BasicBuild.scala | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/stage2/BasicBuild.scala b/stage2/BasicBuild.scala index ebb6a40..18b1754 100644 --- a/stage2/BasicBuild.scala +++ b/stage2/BasicBuild.scala @@ -6,6 +6,13 @@ import java.nio.file._ class BasicBuild(final val context: Context) extends BaseBuild trait BaseBuild extends BuildInterface with DependencyImplementation with SbtDependencyDsl{ + override def equals(other: Any) = { + other match { + case b: BaseBuild => projectDirectory === b.projectDirectory + case _ => false + } + } + //* DO NOT OVERRIDE CONTEXT in non-idempotent ways, because .copy and new Build // will create new instances given the context, which means operations in the // overrides will happen multiple times and if they are not idempotent stuff likely breaks |