This repository has been archived by the owner on Apr 15, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.sbt
54 lines (47 loc) · 1.78 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
import sbt.Compile
import sbt.Keys.libraryDependencies
val doobieVersion = "0.12.1"
val core =
project.in(file("core"))
.settings(commonSettings)
.settings(
libraryDependencies ++= Seq(
"org.typelevel" %% "cats-tagless-macros" % "0.12",
"com.github.julien-truffaut" %% "monocle-core" % "3.0.0-M3"
),
)
def commonSettings = Seq(
scalaVersion := "2.13.5",
scalacOptions ++= {
CrossVersion.partialVersion(scalaVersion.value) match {
case Some((2, n)) if n >= 13 => "-Ymacro-annotations" :: Nil
case _ => Nil
}
},
libraryDependencies ++= {
CrossVersion.partialVersion(scalaVersion.value) match {
case Some((2, n)) if n >= 13 => Nil
case _ => compilerPlugin("org.scalamacros" % "paradise" % "2.1.1" cross CrossVersion.full) :: Nil
}
},
addCompilerPlugin("org.typelevel" % "kind-projector" % "0.11.3" cross CrossVersion.full)
)
val example =
project.in(file("example"))
.settings(commonSettings)
.settings(
scalacOptions += "-Ymacro-annotations",
libraryDependencies ++= Seq(
"org.tpolecat" %% "doobie-core" % doobieVersion,
"org.tpolecat" %% "doobie-postgres" % doobieVersion,
"org.tpolecat" %% "doobie-hikari" % doobieVersion,
"com.github.julien-truffaut" %% "monocle-macro" % "3.0.0-M3",
"org.testcontainers" % "testcontainers" % "1.15.2" % Test,
"com.dimafeng" %% "testcontainers-scala" % "0.39.3" % Test,
"com.spotify" %% "magnolify-scalacheck" % "0.4.3" % Test,
"com.softwaremill.diffx" %% "diffx-specs2" % "0.4.4" % Test,
"org.specs2" %% "specs2-scalacheck" % "4.10.6" % Test,
"com.codecommit" %% "cats-effect-testing-specs2" % "0.5.2" % Test
)
)
.dependsOn(core)