-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sbt
51 lines (41 loc) · 1.48 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
import Dependencies._
version in ThisBuild := "0.5"
scalaVersion in ThisBuild := "2.13.0"
val compilerOptions = Seq(
"-language:postfixOps",
"-language:higherKinds"
)
val scala211 = "2.11.12"
val scala212 = "2.12.9"
val scala213 = "2.13.1"
def createModule(
moduleName: String,
libDependencies: Seq[ModuleID] = Seq.empty,
projectDependencies: Seq[ProjectReference] = Seq.empty,
scalaVersions: Seq[String] = Seq(scala211, scala212, scala213)
) = Project(id = moduleName, base = file(moduleName))
.dependsOn(projectDependencies.map(_ % "compile->compile;test->test"): _*)
.settings(
name := moduleName,
libraryDependencies ++= libDependencies,
test in Test := (test in Test dependsOn
(projectDependencies.map(p => test in Test in p): _*)).value,
scalacOptions ++= compilerOptions,
parallelExecution in Test := false,
crossScalaVersions := scalaVersions
)
lazy val root = (project in file("."))
.settings(
name := "HTypes"
)
.aggregate(
hTypesCore,
hTypesAkkaStream,
hTypesCatsEffect,
hTypesZIO
)
.settings(skip in publish := true)
lazy val hTypesCore = createModule("htypes-core", commonDependencies)
lazy val hTypesAkkaStream = createModule("htypes-akka-stream", commonDependencies ++ akkaStream, Seq(hTypesCore))
lazy val hTypesCatsEffect = createModule("htypes-cats-effect", commonDependencies ++ catsEffect, Seq(hTypesCore))
lazy val hTypesZIO = createModule("htypes-zio", commonDependencies ++ zio, Seq(hTypesCore))