-
Notifications
You must be signed in to change notification settings - Fork 22
/
build.sbt
73 lines (67 loc) · 1.89 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
import BuildHelper._
def scala3Version = "3.3.4"
def scala2Version = "2.13.15"
def projectName = "scala-yaml"
def localSnapshotVersion = "0.2.0-SNAPSHOT"
def isCI = System.getenv("CI") != null
enablePlugins(NoPublishPlugin)
inThisBuild(
List(
organization := "org.virtuslab",
crossScalaVersions := Seq(scala2Version, scala3Version),
scalaVersion := scala3Version,
version ~= { dynVer =>
if (isCI) dynVer
else localSnapshotVersion // only for local publishing
},
homepage := Some(url("https://github.com/VirtusLab/scala-yaml")),
licenses := List(
"Apache-2.0" -> url("http://www.apache.org/licenses/LICENSE-2.0")
),
developers := List(
Developer(
"lwronski",
"Łukasz Wroński",
url("https://github.com/lwronski")
),
Developer(
"kpodsiad",
"Kamil Podsiadło",
url("https://github.com/kpodsiad")
)
)
)
)
ThisBuild / scalafixDependencies += "com.github.liancheng" %% "organize-imports" % "0.6.0"
lazy val core = crossProject(JSPlatform, JVMPlatform, NativePlatform)
.crossType(CrossType.Full)
.withoutSuffixFor(JVMPlatform)
.settings(
name := projectName,
libraryDependencies ++= List(
Deps.munit % Test,
Deps.pprint % Test
),
// add pprint conditionally only on local machines
libraryDependencies ++= {
if (isCI) Nil
else List(Deps.pprint)
}
)
.settings(docsSettings)
lazy val integration = project
.in(file("integration-tests"))
.dependsOn(core.jvm)
.settings(
name := "integration",
moduleName := "integration",
libraryDependencies ++= List(
Deps.munit,
Deps.osLib,
Deps.pprint
),
Compile / doc / sources := Seq.empty
)
.enablePlugins(NoPublishPlugin)