import sbt._ import Process._ class Project(info: ProjectInfo) extends DefaultProject(info) { // ------------------------------------------------------------------------------------------------------------------- // All repositories *must* go here! See ModuleConfigurations below. // ------------------------------------------------------------------------------------------------------------------- object Repositories { // e.g. val AkkaRepo = MavenRepository("Akka Repository", "http://akka.io/repository") } // ------------------------------------------------------------------------------------------------------------------- // ModuleConfigurations // Every dependency that cannot be resolved from the built-in repositories (Maven Central and Scala Tools Releases) // must be resolved from a ModuleConfiguration. This will result in a significant acceleration of the update action. // Therefore, if repositories are defined, this must happen as def, not as val. // ------------------------------------------------------------------------------------------------------------------- import Repositories._ val parboiledModuleConfig = ModuleConfiguration("org.parboiled", ScalaToolsSnapshots) // ------------------------------------------------------------------------------------------------------------------- // Dependencies // ------------------------------------------------------------------------------------------------------------------- val parboiledC = "org.parboiled" % "parboiled-core" % "0.12.0-SNAPSHOT" % "compile" withSources() val parboiledS = "org.parboiled" % "parboiled-scala" % "0.12.0-SNAPSHOT" % "compile" withSources() val specs = "org.scala-tools.testing" %% "specs" % "1.6.7" % "test" withSources() // ------------------------------------------------------------------------------------------------------------------- // Options // ------------------------------------------------------------------------------------------------------------------- override def compileOptions = super.compileOptions ++ Seq("-deprecation", "-encoding", "utf8").map(CompileOption(_)) override def documentOptions: Seq[ScaladocOption] = documentTitle(name + " " + version) :: Nil // ------------------------------------------------------------------------------------------------------------------- // Publishing // ------------------------------------------------------------------------------------------------------------------- val publishTo = "Scala Tools Snapshots" at "http://nexus.scala-tools.org/content/repositories/snapshots/" //val publishTo = "Scala Tools Releases" at "http://nexus.scala-tools.org/content/repositories/releases/" Credentials(Path.userHome / ".ivy2" / ".credentials", log) override def managedStyle = ManagedStyle.Maven override def packageDocsJar = defaultJarPath("-scaladoc.jar") override def packageSrcJar = defaultJarPath("-sources.jar") val sourceArtifact = Artifact(artifactID, "src", "jar", Some("sources"), Nil, None) val docsArtifact = Artifact(artifactID, "docs", "jar", Some("scaladoc"), Nil, None) override def packageToPublishActions = super.packageToPublishActions ++ Seq(packageDocs, packageSrc) override def pomExtra = ( spray JSON http://spray.cc/ 2011 A Scala library for easy and idiomatic JSON (de)serialization Apache 2 http://www.apache.org/licenses/LICENSE-2.0.txt repo sirthias Mathias Doenitz +1 mathias [at] spray.cc http://github.com/spray/spray-json/ ) }