-
Notifications
You must be signed in to change notification settings - Fork 3
/
build.sbt
39 lines (35 loc) · 1.02 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
import org.scalajs.sbtplugin.ScalaJSPlugin.autoImport._
import sbt.Keys._
// Command for building a release
lazy val ReleaseJsCmd = Command.command("releaseJs") {
state =>
"crossJS/fullOptJS" ::
"crossJS/webStage" ::
state
}
lazy val root = project.in(file(".")).
aggregate(jsProject, jvmProject).
settings(
version := Settings.version,
publish := {},
publishLocal := {}
)
lazy val cross = crossProject.in(file(".")).
settings(
name := Settings.name,
version := Settings.version,
scalaVersion := Settings.versions.scala,
persistLauncher in Compile := true,
libraryDependencies ++= Settings.sharedDependencies.value
).
jvmSettings(
libraryDependencies ++= Settings.jvmDependencies.value
).
jsSettings(
libraryDependencies ++= Settings.jsDependencies.value,
jsDependencies ++= Settings.jsScriptDependencies.value,
pipelineStages := Seq(cssCompress),
commands += ReleaseJsCmd
)
lazy val jvmProject = cross.jvm
lazy val jsProject = cross.js.enablePlugins(SbtWeb)