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):just like you would in maven (with
<repository>...</repository>record)Don’t forget to
reloadyour sbt console and thenupdateto fetch the dependency or just start sbt afresh.