title: sbt: publishing plugin to and resolving from local repo
body: <p>I am trying to publish an sbt plugin to a local file repo. In the plugin's build.sbt I have:</p>
  
  <pre><code>publishTo := Some(Resolver.file("localtrix", file("/Users/jast/repo/localtrix")))
  </code></pre>
  
  <p>I run the <code>publish</code> task and it gets published fine to
  <code>/Users/jast/repo/localtrix/org/me/sbt-plugin_2.12_1.0/1.2.3</code></p>
  
  <p>In another project, I want to resolve this plugin. in <code>project/plugins.sbt</code> I have:</p>
  
  <pre><code>resolvers += Resolver.file("localtrix", file("/Users/jast/repo/localtrix"))
  addSbtPlugin("org.me" % "sbt-plugin" % "1.2.3")
  </code></pre>
  
  <p>I try to run sbt in the this project and I get:</p>
  
  <pre><code>[info] Updating ProjectRef(uri("file:/Users/jast/playspace/untitled38/project/"), "untitled38-build")...
  [warn]  module not found: org.me#sbt-plugin;1.2.3
  [warn] ==== typesafe-ivy-releases: tried
  [warn]   https://repo.typesafe.com/typesafe/ivy-releases/org.me/sbt-plugin/scala_2.12/sbt_1.0/1.2.3/ivys/ivy.xml
  [warn] ==== sbt-plugin-releases: tried
  [warn]   https://repo.scala-sbt.org/scalasbt/sbt-plugin-releases/org.me/sbt-plugin/scala_2.12/sbt_1.0/1.2.3/ivys/ivy.xml/2017.2+4-3037ba82+20180314-1919/ivys/ivy.xml
  [warn] ==== local: tried
  [warn]   /Users/jast/.ivy2/local/org.me/sbt-plugin/scala_2.12/sbt_1.0/1.2.3/ivys/ivy.xml
  [warn] ==== public: tried
  [warn]   https://repo1.maven.org/maven2/org/me/sbt-plugin_2.12_1.0/1.2.3/sbt-plugin-1.2.3.pom
  [warn] ==== local-preloaded-ivy: tried
  [warn]   /Users/jast/.sbt/preloaded/org.me/sbt-plugin/scala_2.12/sbt_1.0/1.2.3/ivys/ivy.xml
  [warn] ==== local-preloaded: tried
  [warn]   file:////Users/jast/.sbt/preloaded/org/me/sbt-plugin_2.12_1.0/1.2.3/sbt-plugin-1.2.3.pom
  [warn] ==== localtrix: tried
  [warn]  ::::::::::::::::::::::::::::::::::::::::::::::
  [warn]  ::          UNRESOLVED DEPENDENCIES         ::
  [warn]  ::::::::::::::::::::::::::::::::::::::::::::::
  [warn]  :: org.me#sbt-plugin;1.2.3: not found
  [warn]  ::::::::::::::::::::::::::::::::::::::::::::::
  </code></pre>
  
  <p>So how can I publish to a local repo it in a way that also gets resolved correctly?</p>
  
  <p>Note: <code>publishLocal</code> and resolving from <code>.ivy2/local</code> works, but I want to be able to publish to a repo that I can copy to another machine without messing with that directory.</p>