title: Why does calling sbt.IO.download fail with type mismatch (required: sbt.internals.DslEntry)?
body: <p>I need to download a file with SBT, so I have written a small sbt file with this code in:</p>
  
  <pre><code>    import sbt._
      import java.net.URL
      import java.io.File
  
      lazy val text_url = new URL("http://www.example.com/text.txt")
      lazy val to_file = new File("text.txt")
      sbt.IO.download(text_url, to_file)
  </code></pre>
  
  <p>I have followed the API doc, apparently it is all very simple. However I get a compilation error, which I can not understand:</p>
  
  <pre><code>    /Users/alva/scala_prj/project/plugins.sbt:7: error: type mismatch;
       found   : Unit
       required: sbt.internals.DslEntry
      download(conf_plugin_uri, conf_plugin_file)
  </code></pre>
  
  <p>Maybe I am overlooking something fundamental here, for example some SBT configuration. Can anyone help me pointing me to the right documentation?</p>
  
  <p>Thank you! </p>