aboutsummaryrefslogtreecommitdiff
path: root/stage2/BasicBuild.scala
diff options
context:
space:
mode:
Diffstat (limited to 'stage2/BasicBuild.scala')
-rw-r--r--stage2/BasicBuild.scala12
1 files changed, 10 insertions, 2 deletions
diff --git a/stage2/BasicBuild.scala b/stage2/BasicBuild.scala
index d8d1b8b..d4aa49d 100644
--- a/stage2/BasicBuild.scala
+++ b/stage2/BasicBuild.scala
@@ -31,8 +31,16 @@ trait BaseBuild extends BuildInterface with DependencyImplementation with Trigge
final def crossScalaVersionsArray: Array[String] = crossScalaVersions.to
def projectName = "default"
- // TODO: this should probably provide a nice error message if class has constructor signature
- def copy(context: Context): BuildInterface = lib.copy(this.getClass, context).asInstanceOf[BuildInterface]
+ // TODO: get rid of this in favor of newBuild.
+ // currently blocked on DynamicOverride being not parts
+ // of core but being part of plugin essentials while
+ // callNullary in lib needing .copy .
+ def copy(context: Context): BuildInterface =
+ this.getClass
+ .getConstructor(classOf[Context])
+ .newInstance(context)
+ .asInstanceOf[BuildInterface]
+
def zincVersion = constants.zincVersion
def dependencies: Seq[Dependency] =