This repository has been archived by the owner on Jan 13, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathbuild.sbt
70 lines (63 loc) · 2.42 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
import BuildHelper._
resolvers += Resolver.sonatypeRepo("snapshots")
inThisBuild(
List(
organization := "dev.zio",
testFrameworks += new TestFramework("zio.test.sbt.ZTestFramework"),
scmInfo := Some(
ScmInfo(url("https://github.com/zio/zio-insight/"), "scm:git:[email protected]:zio/zio-insight.git")
)
)
)
addCommandAlias("fmt", "all scalafmtSbt scalafmt test:scalafmt")
addCommandAlias("check", "all scalafmtSbtCheck scalafmtCheck test:scalafmtCheck")
lazy val root =
(project in file("."))
.aggregate(insightsJs, docs)
.settings(
publish / skip := true
)
.enablePlugins(BuildInfoPlugin)
lazy val insights =
crossProject(JSPlatform)
.in(file("zio-insights"))
.settings(
crossScalaVersions := Seq(Version.Scala213, Version.ScalaDotty),
stdSettings("zio.insights"),
libraryDependencies ++= Seq(
"dev.zio" %%% "zio" % Version.zio
)
)
.jsSettings(
crossScalaVersions := Seq(Version.Scala213),
libraryDependencies ++= Seq(
"dev.zio" %%% "zio" % Version.zio,
"dev.zio" %%% "zio-json" % Version.zioJson,
"com.raquo" %%% "laminar" % Version.laminar,
"io.laminext" %%% "websocket" % Version.laminext,
"org.scala-js" %%% "scalajs-java-securerandom" % Version.scalaJsSecureRandom,
"io.github.cquiroz" %%% "scala-java-time" % Version.scalaJavaTime
),
scalaJSLinkerConfig ~= {
_.withModuleKind(ModuleKind.ESModule)
},
scalaJSLinkerConfig ~= {
_.withSourceMap(true)
},
scalaJSUseMainModuleInitializer := true
)
.settings(buildInfoSettings("zio.insights"))
.enablePlugins(BuildInfoPlugin)
lazy val insightsJs = insights.js
lazy val docs = project
.in(file("zio-insight-docs"))
.settings(
moduleName := "zio-insight-docs",
libraryDependencies ++= Seq("dev.zio" %% "zio" % Version.zio),
projectName := "ZIO Insight",
mainModuleName := (insightsJs / moduleName).value,
projectStage := ProjectStage.Development,
ScalaUnidoc / unidoc / unidocProjectFilter := inProjects(insightsJs),
docsPublishBranch := "main"
)
.enablePlugins(WebsitePlugin)