-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.sbt
67 lines (61 loc) · 1.86 KB
/
build.sbt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
import EclipseKeys._
lazy val projectSettings = Seq(
organization := "com.loopfor.rpn",
version := "0.1",
licenses := Seq("Apache License, Version 2.0" -> url("http://www.apache.org/licenses/LICENSE-2.0.txt"))
)
lazy val compilerSettings = Seq(
scalaVersion := "2.11.6",
crossPaths := false,
scalacOptions ++= Seq(
"-deprecation",
"-unchecked",
"-feature",
"-encoding", "UTF-8"
),
javacOptions ++= Seq(
"-source", "1.6",
"-target", "1.6"
)
)
lazy val dependencySettings = Seq(
libraryDependencies ++= Seq(
"org.scalatest" %% "scalatest" % "2.2.4" % "test"
)
)
lazy val publishSettings = Seq(
pomIncludeRepository := { _ => false },
pomExtra :=
<developers>
<developer>
<id>davidledwards</id>
<name>David Edwards</name>
<email>[email protected]</email>
</developer>
</developers>,
publishTo := Some(
if (version.value endsWith "SNAPSHOT")
"Sonatype Nexus Snapshot Repository" at "https://oss.sonatype.org/content/repositories/snapshots/"
else
"Sonatype Nexus Release Repository" at "https://oss.sonatype.org/service/local/staging/deploy/maven2/"
)
)
lazy val eclipseSettings = Seq(
eclipseOutput in Compile := (classDirectory in Compile).value relativeTo baseDirectory.value map { _.getPath },
eclipseOutput in Test := (classDirectory in Test).value relativeTo baseDirectory.value map { _.getPath }
)
lazy val rootProject = (project in file(".")).
settings(
name := "rpn",
description := "RPN Compiler and Interpreter"
).
settings(projectSettings: _*).
settings(compilerSettings: _*).
settings(dependencySettings: _*).
settings(publishSettings: _*).
settings(eclipseSettings: _*).
settings(packSettings).
settings(
packMain := Map("rpnc" -> "com.loopfor.rpn.Compiler",
"rpn" -> "com.loopfor.rpn.Interpreter")
)