Note that there are some explanatory texts on larger screens.

plurals
  1. PONo implicit for Append.Value[...] found with Def.task to generate files in SBT 0.13?
    text
    copied!<p>I'm having an issue migrating my project to SBT <code>0.13</code>.</p> <p>For some reason, the snippet from <a href="http://www.scala-sbt.org/release/docs/Howto/generatefiles.html#sources" rel="nofollow noreferrer">Generate sources</a> from the SBT documentation doesn't work for me.</p> <p>Neither a simple <code>.sbt</code> build definition nor a Scala build definition work, unfortunately. Project definition is taken from the documentation:</p> <pre><code>name := "sbt-test" sourceGenerators in Compile += Def.task { val file = (sourceManaged in Compile).value / "demo" / "Test.scala" IO.write(file, """object Test extends App { println("Hi") }""") Seq(file) } </code></pre> <p>The compiler complains about the type error when compiling the project definition:</p> <pre><code>~/P/sbt-test ▶ sbt [info] Loading global plugins from /Users/phearnot/.sbt/0.13/plugins [info] Loading project definition from /Users/phearnot/Projects/sbt-test/project /Users/phearnot/Projects/sbt-test/build.sbt:3: error: No implicit for Append.Value[Seq[sbt.Task[Seq[java.io.File]]], sbt.std.FullInstance.M[Seq[java.io.File]]] found, so sbt.std.FullInstance.M[Seq[java.io.File]] cannot be appended to Seq[sbt.Task[Seq[java.io.File]]] sourceGenerators in Compile += Def.task { ^ [error] Type error in expression Project loading failed: (r)etry, (q)uit, (l)ast, or (i)gnore? </code></pre> <p><strong>UPDATE:</strong> Now that <a href="https://stackoverflow.com/users/1078381/alexiv">AlexIv</a> has pointed out the problem in my SBT file definition, I wonder what is the proper way to move it into a Scala build definition?</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload