diff --git a/project/build.properties b/project/build.properties deleted file mode 100644 index f4864c146..000000000 --- a/project/build.properties +++ /dev/null @@ -1,2 +0,0 @@ -#Project properties -sbt.version=0.13.9 diff --git a/project/build.scala b/project/build.scala deleted file mode 100644 index dae0f8a0d..000000000 --- a/project/build.scala +++ /dev/null @@ -1,96 +0,0 @@ -import sbt._ -import Keys._ -import com.earldouglas.xwp._ -import com.earldouglas.xwp.WebappPlugin -import com.earldouglas.xwp.ContainerPlugin.autoImport._ - - -object LiftProjectBuild extends Build { - override lazy val settings = super.settings ++ buildSettings - - lazy val buildSettings = Seq( - organization := pom.groupId, - version := pom.version - ) - - lazy val openBank = Project( - pom.artifactId, - base = file("."), - settings = defaultSettings ++ pom.settings) - .enablePlugins(JettyPlugin) - - object pom { - - val pomFile = "pom.xml" - lazy val pom = xml.XML.loadFile(pomFile) - - lazy val pomProperties = (for{ - props <- (pom \ "properties") - p <- props.child - } yield { - p.label -> p.text - }).toMap - - private lazy val PropertiesExpr = """.*\$\{(.*?)\}.*""".r - - def populateProps(t: String) = t match { - case PropertiesExpr(p) => { - val replaceWith = pomProperties.get(p) - t.replace("${"+p+"}", replaceWith.getOrElse(throw new Exception("Cannot find property: '" + p + "' required by: '" + t + "' in: " + pomFile))) - } - case _ => t - } - - lazy val pomDeps = (for{ - dep <- pom \ "dependencies" \ "dependency" - } yield { - val scope = (dep \ "scope") - val groupId = (dep \ "groupId").text - val noScope = populateProps(groupId) % populateProps((dep \ "artifactId").text) % populateProps((dep \ "version").text) - val nonCustom = if (scope.nonEmpty) noScope % populateProps(scope.text) - else noScope - - if (groupId.endsWith("jetty")) Seq(noScope % "container", nonCustom) //hack to add jetty deps in container scope as it is required by the web plugin - else Seq(nonCustom) - }).flatten - - lazy val pomRepos = for { - rep <- pom \ "repositories" \ "repository" - } yield { - populateProps((rep \ "url").text) at populateProps((rep \ "url").text) - } - - lazy val pomScalaVersion = (pom \ "properties" \ "scala.compiler").text - - lazy val artifactId = (pom \ "artifactId").text - lazy val groupId = (pom \ "groupId").text - lazy val version = (pom \ "version").text - lazy val name = (pom \ "name").text - - lazy val settings = Seq( - scalaVersion := pomScalaVersion, - libraryDependencies ++= pomDeps, - resolvers ++= pomRepos, - containerPort := 8080 - ) - - } - - lazy val defaultSettings = Defaults.defaultSettings ++ Seq( - name := pom.name, - resolvers ++= Seq( - "Typesafe Repo" at "http://repo.typesafe.com/typesafe/releases", - "Java.net Maven3 Repository" at "http://download.java.net/maven/3/", - "Scala-Tools Dependencies Repository for Releases" at "http://scala-tools.org/repo-releases", - "Scala-Tools Dependencies Repository for Snapshots" at "http://scala-tools.org/repo-snapshots"), - - // compile options - scalacOptions ++= Seq("-encoding", "UTF-8", "-deprecation", "-unchecked", "-Xmax-classfile-name", "78"), - javacOptions ++= Seq("-Xlint:unchecked", "-Xlint:deprecation"), - - // show full stack traces - testOptions in Test += Tests.Argument("-oF") - ) - -} - diff --git a/project/plugins.sbt b/project/plugins.sbt deleted file mode 100644 index 3642ac1be..000000000 --- a/project/plugins.sbt +++ /dev/null @@ -1,30 +0,0 @@ -resolvers += Classpaths.typesafeResolver - -// addSbtPlugin("com.typesafe.sbteclipse" % "sbteclipse" % "1.5.0") - -// resolvers += "sbt-deploy-repo" at "http://reaktor.github.com/sbt-deploy/maven" -// addSbtPlugin("fi.reaktor" %% "sbt-deploy" % "0.3.1-SNAPSHOT") - - -//xsbt-web-plugin - -addSbtPlugin("com.earldouglas" % "xsbt-web-plugin" % "2.1.0") - -//resolvers += "Web plugin repo" at "http://siasia.github.com/maven2" - -//libraryDependencies <+= sbtVersion(v => "com.github.siasia" % "xsbt-web-plugin" % (v+"-0.2.11")) - -//sbteclipse -resolvers += { - val typesafeRepoUrl = new java.net.URL("http://repo.typesafe.com/typesafe/releases") - val pattern = Patterns(false, "[organisation]/[module]/[sbtversion]/[revision]/[type]s/[module](-[classifier])-[revision].[ext]") - Resolver.url("Typesafe Repository", typesafeRepoUrl)(pattern) -} - -addSbtPlugin("com.typesafe.sbteclipse" % "sbteclipse-plugin" % "4.0.0") -addSbtPlugin("net.virtual-void" % "sbt-dependency-graph" % "0.8.2") - -//sbt-idea -resolvers += "sbt-idea-repo" at "http://mpeltonen.github.com/maven/" - -addSbtPlugin("com.github.mpeltonen" % "sbt-idea" % "1.6.0") diff --git a/sbt.sh b/sbt.sh deleted file mode 100755 index 723ed2acf..000000000 --- a/sbt.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/sh - -export SBT_OPTS="-Xmx1024m -Xms1024m -Xss2048k -XX:MaxPermSize=1024m" -echo "sbt $@" -sbt $@ - -#$1 $2 $3 $4