A quick note how to create a SBT project with the latest release of Akka.
Create a build.sbt file:
name := "ScalaAkkaTest"
organization := "&lt;Your organisation name&gt;"
version := "0.1.0-SNAPSHOT"
scalaVersion := "2.11.2"
resolvers += "Typesafe Repository" at "http://repo.typesafe.com/typesafe/releases/"
libraryDependencies += "com.typesafe.akka" %% "akka-actor" % "2.3.6"
I was creating a servlet using Scala and got the following error message “To compile XML syntax, the scala.xml package must be on the classpath”. It turns out that Scala-XML has been factored out into a separate library as of Scala 2.11, so it is not included in Scala projects by default. So the dependency needs to be include in the project build.sbt using the following statement:
libraryDependencies += "org.scala-lang.modules" %% "scala-xml" % "1.0.2"
Note as always you should check that there isn’t a newer version available of the library. How? Google is your friend 🙂
maven org.scala-lang.modules scala-xml
This is a quick start tutorial to get going with SBT. It is meant for myself, but you are welcome to use it too 🙂
For the detailed documentation please checkout the documentation on the SBT website. Continue reading