-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathbuild.sbt
78 lines (68 loc) · 2.51 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
import Dependencies._
import sbt.{Test, ThisBuild}
lazy val scala212 = "2.12.16"
lazy val scala213 = "2.13.10"
lazy val supportedScalaVersions = List(scala212, scala213)
ThisBuild / scalaVersion := "2.13.8"
ThisBuild / version := "0.0.7"
ThisBuild / organization := "io.github.mbannour"
ThisBuild / organizationName := "mbannour"
ThisBuild / description := "ZIO wrapper for MongoDB Reactive Streams Java Driver"
ThisBuild / scmInfo := Some(ScmInfo(url("https://github.com/mbannour/zio-mongo"), "https://github.com/mbannour/zio-mongo.git"))
ThisBuild / developers := List(Developer("", "medali", "med.ali.bennour@gmail.com", url("https://github.com/mbannour")))
ThisBuild / licenses := List("Apache-2.0" -> url("http://www.apache.org/licenses/LICENSE-2.0"))
ThisBuild / homepage := Some(url("https://github.com/mbannour/zio-mongo"))
ThisBuild / versionScheme := Some("early-semver")
lazy val scalaOptions =
Seq(
"-encoding", "utf-8",
"-deprecation",
"-explaintypes",
"-unchecked",
"-feature",
"-language:existentials",
"-language:higherKinds",
"-language:implicitConversions",
"-Xcheckinit"
)
lazy val ziomongo = (project in file("."))
.settings(
crossScalaVersions := Nil,
publish / skip := true
)
.aggregate(zioCore, examples)
lazy val zioCore = (project in file("zio-core"))
.settings(
name := "ziomongo",
ThisBuild / publishTo := {
val nexus = "https://s01.oss.sonatype.org/"
if (isSnapshot.value) Some("snapshots" at nexus + "content/repositories/snapshots")
else Some("releases" at nexus + "service/local/staging/deploy/maven2")
},
ThisBuild / publishMavenStyle := true,
Test / packageBin / publishArtifact := false,
scalacOptions ++= scalaOptions,
crossScalaVersions := supportedScalaVersions,
credentials += Credentials(Path.userHome / ".sbt" / "sonatype_credentials"),
libraryDependencies ++= Seq(
mongoScala,
logback,
zio,
zioIntStream,
zioStreams,
slf4j,
zioMagnoliaTest % Test,
zioTestSbt % Test,
zioTest % Test,
scalaTest % Test
),
testFrameworks += new TestFramework("zio.test.sbt.ZTestFramework"),
Test / testOptions ++= Seq(Tests.Setup(() => MongoEmbedded.start), Tests.Cleanup(() => MongoEmbedded.stop)),
Test / parallelExecution := false
)
lazy val examples = (project in file("zio-examples"))
.settings(
crossScalaVersions := Nil,
publish / skip := true
)
.dependsOn(zioCore)