My SBT don't have 'sbt-launch.jar'.
If SBT is properly installed, then there is a sbt-launch.jar
somwhere. Assuming you installed SBT with the DEB package, you should be able to list installed files with the command dpkg -L sbt
.
locally installed SBT version :0.13.11 ( in Ubuntu file system, it is with " .sbt " name, as hidden folder)
Sounds like you are talking about the ~/.sbt
folder? This is SBT's default location for storing user data (user-specific configuration, but also some cached downloads), not the installation folder.
But I want to use locally installed sbt,scala versions.
There are actually three elements to consider:
- The SBT laucher (
sbt-launch.jar
)
- SBT itself
- Scala (compiler & standard library)
For the SBT launcher, you can use your own install or let Intellij download its own copy.
For SBT, realistically, I think it will have to be downloaded by the SBT launcher. The version of SBT to use is specified in <my project>/project/build.properties
.
For Scala, you can let SBT download it (usually recommended; configure the version to use in your build.sbt
) or use a local version.
If you really want to use a local Scala version, this is explained in the SBT documentation: you should just need to configure scalaHome
in you build.sbt
:
scalaHome := Some(file("/home/user/scala-2.10/"))
But keep in mind that this will make you build less repeatable, both on other computers or on the same computer after a few months have passed... And managing several projects which may require different versions of Scala will also be more difficult.