forked from VladKopanev/zio-saga
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sbt
126 lines (118 loc) · 3.93 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
import com.typesafe.sbt.SbtPgp.autoImportImpl.pgpSecretRing
import sbt.file
name := "zio-saga"
val mainScala = "2.12.8"
val allScala = Seq("2.11.12", mainScala)
inThisBuild(
List(
organization := "com.vladkopanev",
homepage := Some(url("https://github.com/VladKopanev/zio-saga")),
licenses := List("MIT License" -> url("https://opensource.org/licenses/MIT")),
developers := List(
Developer(
"VladKopanev",
"Vladislav Kopanev",
url("http://vladkopanev.com")
)
),
scmInfo := Some(
ScmInfo(url("https://github.com/VladKopanev/zio-saga"), "scm:git:[email protected]/VladKopanev/zio-saga.git")
),
pgpPublicRing := file("./travis/local.pubring.asc"),
pgpSecretRing := file("./travis/local.secring.asc"),
releaseEarlyWith := SonatypePublisher
)
)
lazy val commonSettings = Seq(
scalaVersion := mainScala,
scalacOptions ++= Seq(
"-deprecation",
"-encoding",
"UTF-8",
"-explaintypes",
"-Yrangepos",
"-feature",
"-Xfuture",
"-language:higherKinds",
"-language:existentials",
"-language:implicitConversions",
"-unchecked",
"-Xlint:_,-type-parameter-shadow",
"-Ywarn-numeric-widen",
"-Ywarn-unused",
"-Ywarn-value-discard"
) ++ (CrossVersion.partialVersion(scalaVersion.value) match {
case Some((2, 11)) =>
Seq(
"-Yno-adapted-args",
"-Ypartial-unification",
"-Ywarn-inaccessible",
"-Ywarn-infer-any",
"-Ywarn-nullary-override",
"-Ywarn-nullary-unit"
)
case Some((2, 12)) =>
Seq(
"-Xsource:2.13",
"-Yno-adapted-args",
"-Ypartial-unification",
"-Ywarn-extra-implicit",
"-Ywarn-inaccessible",
"-Ywarn-infer-any",
"-Ywarn-nullary-override",
"-Ywarn-nullary-unit",
"-opt-inline-from:<source>",
"-opt-warnings",
"-opt:l:inline"
)
case _ => Nil
}),
scalacOptions ++= Seq("-Ypartial-unification"),
resolvers ++= Seq(Resolver.sonatypeRepo("snapshots"), Resolver.sonatypeRepo("releases"))
)
lazy val root = project
.in(file("."))
.dependsOn(examples)
.aggregate(core)
lazy val core = project
.in(file("core"))
.settings(
commonSettings,
name := "zio-saga-core",
coverageEnabled := true,
crossScalaVersions := allScala,
libraryDependencies ++= Seq(
"org.scalaz" %% "scalaz-zio" % "1.0-RC5",
"org.scalactic" %% "scalactic" % "3.0.5",
"org.scalatest" %% "scalatest" % "3.0.5" % "test"
)
)
val http4sVersion = "0.20.1"
val log4CatsVersion = "0.3.0"
val doobieVersion = "0.7.0"
val circeVersion = "0.11.1"
lazy val examples = project
.in(file("examples"))
.settings(
commonSettings,
coverageEnabled := false,
libraryDependencies ++= Seq(
"ch.qos.logback" % "logback-classic" % "1.2.3",
"io.chrisdavenport" %% "log4cats-core" % log4CatsVersion,
"io.chrisdavenport" %% "log4cats-slf4j" % log4CatsVersion,
"io.circe" %% "circe-generic" % circeVersion,
"io.circe" %% "circe-parser" % circeVersion,
"org.http4s" %% "http4s-circe" % http4sVersion,
"org.http4s" %% "http4s-dsl" % http4sVersion,
"org.http4s" %% "http4s-blaze-server" % http4sVersion,
"org.scalaz" %% "scalaz-zio-interop-cats" % "1.0-RC5",
"org.tpolecat" %% "doobie-core" % doobieVersion,
"org.tpolecat" %% "doobie-hikari" % doobieVersion,
"org.tpolecat" %% "doobie-postgres" % doobieVersion,
compilerPlugin("org.scalamacros" % "paradise" % "2.1.0" cross CrossVersion.full),
compilerPlugin("org.spire-math" %% "kind-projector" % "0.9.9"),
compilerPlugin("com.olegpy" %% "better-monadic-for" % "0.3.0-M4")
)
)
.dependsOn(core % "test->test;compile->compile")