1

I have added resolvers += Resolver.mavenLocal the the plugins.sbt file However sbt only seems to resolve ~/.ivi and not ~/.m2 repository. How can I change that?

I tried this as well but it did not seem to work

resolvers += "Local m2y" at Path.userHome.asFile.toURI.toURL + ".m2/repository"

edit

the error message enter image description here but the file is there enter image description here

Georg Heiler
  • 16,916
  • 36
  • 162
  • 292

2 Answers2

3

Try this:

resolvers += "Local Maven Repository" at "file://"+Path.userHome.absolutePath+"/.m2/repository"
mgosk
  • 1,874
  • 14
  • 23
  • Unfortunately, this does not seem to do the trick. I updated the post to reflect the error mesage / proof that the file is there in the m2 folder. Strangely the MavenLocal resolver works just fine on my mac - but apparently not on linux. – Georg Heiler Nov 21 '16 at 13:12
  • It is possible that You need to use different variables to extract user home. – mgosk Apr 04 '18 at 20:43
2

If you are using repositories file, you can add maven-local alongwith local. Reference -> https://www.scala-sbt.org/1.x/docs/Launcher-Configuration.html#3.+Repositories+Section

nishantv
  • 643
  • 4
  • 9
  • 27