This repository has been archived by the owner on Oct 28, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 30
/
build.sbt
126 lines (115 loc) · 3.76 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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
// *****************************************************************************
// Projects
// *****************************************************************************
lazy val `akka-sse` =
project
.in(file("."))
.enablePlugins(GitVersioning)
.aggregate(core, example, jmh)
.settings(settings)
.settings(
unmanagedSourceDirectories.in(Compile) := Seq.empty,
unmanagedSourceDirectories.in(Test) := Seq.empty,
publishArtifact := false
)
lazy val core =
project
.enablePlugins(AutomateHeaderPlugin)
.settings(settings)
.settings(
name := "akka-sse",
libraryDependencies ++= Seq(
library.akkaHttp,
library.akkaHttpTestkit % Test,
library.junit % Test,
library.scalaCheck % Test,
library.scalaTest % Test
)
)
lazy val example =
project
.enablePlugins(AutomateHeaderPlugin)
.dependsOn(core)
.settings(settings)
.settings(
libraryDependencies ++= Seq(
library.akkaHttp
),
publishArtifact := false
)
lazy val jmh =
project
.enablePlugins(AutomateHeaderPlugin, JmhPlugin)
.dependsOn(core)
.settings(settings)
.settings(
libraryDependencies ++= Seq(
library.akkaStream
),
publishArtifact := false
)
// *****************************************************************************
// Library dependencies
// *****************************************************************************
lazy val library =
new {
object Version {
val akka = "2.5.1"
val akkaHttp = "10.0.6"
val junit = "4.12"
val scalaCheck = "1.13.5"
val scalaTest = "3.0.3"
}
val akkaHttp = "com.typesafe.akka" %% "akka-http" % Version.akkaHttp
val akkaHttpTestkit = "com.typesafe.akka" %% "akka-http-testkit" % Version.akkaHttp
val akkaStream = "com.typesafe.akka" %% "akka-stream" % Version.akka
val junit = "junit" % "junit" % Version.junit
val scalaCheck = "org.scalacheck" %% "scalacheck" % Version.scalaCheck
val scalaTest = "org.scalatest" %% "scalatest" % Version.scalaTest
}
// *****************************************************************************
// Settings
// *****************************************************************************
lazy val settings =
commonSettings ++
gitSettings ++
publishSettings
lazy val commonSettings =
Seq(
// scalaVersion from .travis.yml
// crossScalaVersions from .travis.yml
organization := "de.heikoseeberger",
organizationName := "Heiko Seeberger",
startYear := Some(2015),
licenses += ("Apache-2.0", url("http://www.apache.org/licenses/LICENSE-2.0")),
scalacOptions ++= Seq(
"-unchecked",
"-deprecation",
"-language:_",
"-target:jvm-1.8",
"-encoding", "UTF-8"
),
javacOptions ++= Seq(
"-source", "1.8",
"-target", "1.8"
),
unmanagedSourceDirectories.in(Compile) :=
Seq(scalaSource.in(Compile).value, javaSource.in(Compile).value),
unmanagedSourceDirectories.in(Test) :=
Seq(scalaSource.in(Test).value, javaSource.in(Test).value)
)
lazy val gitSettings =
Seq(
git.useGitDescribe := true
)
lazy val publishSettings =
Seq(
homepage := Some(url("https://github.com/hseeberger/akka-sse")),
scmInfo := Some(ScmInfo(url("https://github.com/hseeberger/akka-sse"),
"git@github.com:hseeberger/akka-sse.git")),
developers += Developer("hseeberger",
"Heiko Seeberger",
"mail@heikoseeberger.de",
url("https://github.com/hseeberger")),
pomIncludeRepository := (_ => false)
)