summaryrefslogtreecommitdiff
path: root/project
diff options
context:
space:
mode:
authorTrygve Laugstøl <trygvis@inamo.no>2013-05-19 01:14:42 +0200
committerTrygve Laugstøl <trygvis@inamo.no>2013-05-19 10:21:38 +0200
commitc569a4c58cf29778df28392b48e20ffebdbc518e (patch)
tree5148d1bd03b8efbb281fb4c4dc66d63cc38cf1c9 /project
downloadcollection-json-explorer-scala-c569a4c58cf29778df28392b48e20ffebdbc518e.tar.gz
collection-json-explorer-scala-c569a4c58cf29778df28392b48e20ffebdbc518e.tar.bz2
collection-json-explorer-scala-c569a4c58cf29778df28392b48e20ffebdbc518e.tar.xz
collection-json-explorer-scala-c569a4c58cf29778df28392b48e20ffebdbc518e.zip
o Initial import of the Scala version of the Collection+JSON explorer.
Diffstat (limited to 'project')
-rw-r--r--project/Build.scala84
-rw-r--r--project/build.properties1
-rw-r--r--project/plugins.sbt5
3 files changed, 90 insertions, 0 deletions
diff --git a/project/Build.scala b/project/Build.scala
new file mode 100644
index 0000000..1542f8f
--- /dev/null
+++ b/project/Build.scala
@@ -0,0 +1,84 @@
+import sbt._
+import sbt.Keys._
+import xml.Group
+import aether._
+
+object Build extends sbt.Build {
+
+ lazy val buildSettings = Defaults.defaultSettings ++ Aether.aetherPublishSettings ++ Seq(
+ organization := "io.trygvis",
+ scalaVersion := "2.10.0",
+// crossScalaVersions := Seq("2.9.1", "2.9.2", "2.10.0"),
+ scalacOptions := Seq("-deprecation"),
+ publishTo <<= (version) apply {
+ (v: String) => if (v.trim().endsWith("SNAPSHOT")) Some(Resolvers.sonatypeNexusSnapshots) else Some(Resolvers.sonatypeNexusStaging)
+ },
+ pomIncludeRepository := { x => false },
+ credentials += Credentials(Path.userHome / ".sbt" / ".credentials")
+ )
+
+ lazy val root = Project(
+ id = "collection-json-explorer",
+ base = file("."),
+ settings = buildSettings ++ Seq(
+ description := "Collection+JSON Explorer",
+ name := "collection-json-explorer",
+ libraryDependencies += "net.hamnaberg.rest" %% "scala-json-collection" % "2.1-SNAPSHOT",
+ libraryDependencies += "net.databinder" %% "unfiltered-filter" % "0.6.8",
+ libraryDependencies += "net.databinder" %% "unfiltered-directives" % "0.6.8",
+ libraryDependencies += "net.databinder" %% "unfiltered-jetty" % "0.6.8",
+ libraryDependencies += "net.databinder" %% "unfiltered-netty" % "0.6.8",
+ libraryDependencies <+= scalaVersion { sv =>
+ val ver = if (sv.startsWith("2.10")) "1.13" else "1.12.3"
+ "org.specs2" %% "specs2" % ver % "test"
+ }/*,
+ manifestSetting*/
+ ) ++ mavenCentralFrouFrou
+ )
+
+ object Resolvers {
+ val sonatypeNexusSnapshots = "Sonatype Nexus Snapshots" at "https://oss.sonatype.org/content/repositories/snapshots"
+ val sonatypeNexusStaging = "Sonatype Nexus Staging" at "https://oss.sonatype.org/service/local/staging/deploy/maven2"
+ }
+
+ /*
+ lazy val manifestSetting = packageOptions <+= (name, version, organization) map {
+ (title, version, vendor) =>
+ Package.ManifestAttributes(
+ "Created-By" -> "Simple Build Tool",
+ "Built-By" -> System.getProperty("user.name"),
+ "Build-Jdk" -> System.getProperty("java.version"),
+ "Specification-Title" -> title,
+ "Specification-Version" -> version,
+ "Specification-Vendor" -> vendor,
+ "Implementation-Title" -> title,
+ "Implementation-Version" -> version,
+ "Implementation-Vendor-Id" -> vendor,
+ "Implementation-Vendor" -> vendor
+ )
+ }
+ */
+
+ // Things we care about primarily because Maven Central demands them
+ lazy val mavenCentralFrouFrou = Seq(
+// homepage := Some(new URL("http://github.com/hamnis/scala-collection-json/")),
+ startYear := Some(2013),
+ licenses := Seq(("Apache 2", new URL("http://www.apache.org/licenses/LICENSE-2.0.txt")))/*,
+ pomExtra <<= (pomExtra, name, description) {(pom, name, desc) => pom ++ Group(
+ <scm>
+ <url>http://github.com/hamnis/scala-collection-json</url>
+ <connection>scm:git:git://github.com/hamnis/scala-collection-json.git</connection>
+ <developerConnection>scm:git:git@github.com:hamnis/scala-collection-json.git</developerConnection>
+ </scm>
+ <developers>
+ <developer>
+ <id>hamnis</id>
+ <name>Erlend Hamnaberg</name>
+ <url>http://twitter.com/hamnis</url>
+ </developer>
+ </developers>
+ )}
+ */
+ )
+ }
+
diff --git a/project/build.properties b/project/build.properties
new file mode 100644
index 0000000..1a27d70
--- /dev/null
+++ b/project/build.properties
@@ -0,0 +1 @@
+bt.version=0.12.1
diff --git a/project/plugins.sbt b/project/plugins.sbt
new file mode 100644
index 0000000..8270680
--- /dev/null
+++ b/project/plugins.sbt
@@ -0,0 +1,5 @@
+resolvers += "Sonatype snapshots" at "http://oss.sonatype.org/content/repositories/snapshots/"
+
+addSbtPlugin("com.github.mpeltonen" % "sbt-idea" % "1.3.0-SNAPSHOT")
+
+addSbtPlugin("no.arktekk.sbt" % "aether-deploy" % "0.7")