I'm setting up the dependencies for my first Scala project using SBT.
This is my build.sbt
file:
name := "MyProj"
version := "1.0"
scalaVersion := "2.9.2"
libraryDependencies += "org.eclipse.jgit" % "org.eclipse.jgit" % "2.0.0.201206130900-r"
When I run update
inside the interactive mode, it updates something from org.scala-lang...
but it never downloads my dependencies. How do I get it to install/download dependencies?
Some of the common repositories are already predefined, but it looks like your library is not in them, so you have to add the Eclipse repository to the list of resolvers (add this line to build.sbt
):
resolvers += "jgit-repository" at "http://download.eclipse.org/jgit/maven"
just like you would in maven (with <repository>...</repository>
record)
Don't forget to reload
your sbt console and then update
to fetch the dependency or just start sbt afresh.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With