diff --git a/src/main/scala/com/thoughtworks/Example.scala b/src/main/scala/com/thoughtworks/Example.scala index c2d274f..2cfa8d3 100644 --- a/src/main/scala/com/thoughtworks/Example.scala +++ b/src/main/scala/com/thoughtworks/Example.scala @@ -3,6 +3,7 @@ import java.io.File import sbt.Keys._ import sbt._ +import sbt.nio.Keys._ import sbt.plugins.JvmPlugin import scala.collection.immutable @@ -406,12 +407,13 @@ object Example extends AutoPlugin { } }, + generateExample / fileInputs := (Compile / unmanagedSources / fileInputs).value, generateExample := { val outputFile = (sourceManaged in Test).value / "sbt-example-generated.scala" val logger = (streams in generateExample).value.log val compileDialect = (Compile / exampleDialect).value val testDialect = (Test / autoImport.exampleDialect).value - val content = (unmanagedSources in Compile).value.view.flatMap { file => + val content = generateExample.inputFiles.view.flatMap { file => val source = new ScalametaParser(Input.File(file))(compileDialect).parseSource() exampleStats(source, logger, testDialect) }.toList