title: Sbt / javaAgents / force jar-with-dependencies
body: <p>I want to add <code>"org.kohsuke" % "file-leak-detector" % "1.13"</code>  java agent to my sbt configuration. </p>
  
  <pre class="lang-scala prettyprint-override"><code>//plugins.sbt
  addSbtPlugin("com.lightbend.sbt" % "sbt-javaagent" % "0.1.5")
  
  //build.sbt
  enablePlugins(SbtWeb, PlayScala, DebianPlugin, JavaAgent)
  javaAgents += "org.kohsuke" % "file-leak-detector" % "1.13"
  </code></pre>
  
  <p>but this failed at runtime. </p>
  
  <pre><code>Failed to find Premain-Class manifest attribute in /usr/share/someApp/bin/../file-leak-detector/file-leak-detector-1.13.jar
  Error occurred during initialization of VM
  agent library failed to init: instrument
  </code></pre>
  
  <p>I've found that i need jar with dependencies to run it as javaAgent but event if I theoretically could download it from <a href="https://repo1.maven.org/maven2/org/kohsuke/file-leak-detector/1.13/" rel="nofollow noreferrer">https://repo1.maven.org/maven2/org/kohsuke/file-leak-detector/1.13/</a>
  I don't know how to use it with <code>sbt-javaagent</code> plugin.</p>
  
  <p>I have tried also: </p>
  
  <pre class="lang-scala prettyprint-override"><code>javaAgents += ("org.kohsuke" % "file-leak-detector" % "1.13") from "https://repo1.maven.org/maven2/org/kohsuke/file-leak-detector/1.13/file-leak-detector-1.13-jar-with-dependencies.jar"
  </code></pre>
  
  <p>but without luck. Any ideas how to force sbt-javaagent plugin to use <code>file-leak-detector-1.13-jar-with-dependencies.jar</code> instead of <code>file-leak-detector-1.13-jar</code>?</p>