forked from datamindedbe/lighthouse
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sbt
53 lines (48 loc) · 2.23 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
import Dependencies._
import Predef._
import Resolvers._
import sbt.Opts.resolver.sonatypeStaging
lazy val buildSettings = Seq(
organization := "be.dataminded",
scalaVersion := scala211,
crossScalaVersions := Nil,
// Ensure code quality
scalafmtOnCompile := true,
// Memory settings to be able to test with Spark
Test / fork := true,
Test / testOptions += Tests.Argument("-oD"),
javaOptions ++= Seq(
"-Xms768M",
"-Xmx2048M",
"-XX:+CMSClassUnloadingEnabled",
"-Dspark.sql.shuffle.partitions=2",
"-Dspark.shuffle.sort.bypassMergeThreshold=2",
"-Dlighthouse.environment=test"
),
scalacOptions ++= Seq("-Ypartial-unification", "-deprecation"),
// Git versioning
git.useGitDescribe := true,
git.baseVersion := "0.0.0",
// Publish like Maven
publishMavenStyle := true,
publishTo := Some(if (isSnapshot.value) datamindedSnapshots else sonatypeStaging),
homepage := Some(url("https://github.com/datamindedbe/lighthouse")),
scmInfo := Some(
ScmInfo(url("https://github.com/datamindedbe/lighthouse"), "[email protected]:datamindedbe/lighthouse.git")),
developers := List(
Developer("mlavaert", "Mathias Lavaert", "[email protected]", url("https://github.com/mlavaert"))),
licenses += ("Apache-2.0", url("http://www.apache.org/licenses/LICENSE-2.0"))
)
lazy val `lighthouse-platform` = (project in file("."))
.settings(buildSettings, publishArtifact := false)
.enablePlugins(GitVersioning)
.aggregate(lighthouse, `lighthouse-testing`, `lighthouse-demo`)
lazy val lighthouse = (project in file("lighthouse-core"))
.dependsOn(`lighthouse-testing` % "test->compile")
.enablePlugins(SiteScaladocPlugin)
.settings(buildSettings, libraryDependencies ++= commonDependencies ++ Seq(cats, typesafeConfig), crossScalaVersions := supportedScalaVersions)
lazy val `lighthouse-testing` = (project in file("lighthouse-testing"))
.settings(buildSettings, libraryDependencies ++= Seq(sparkSql, sparkHive, scalaTest, betterFiles), crossScalaVersions := supportedScalaVersions)
lazy val `lighthouse-demo` = (project in file("lighthouse-demo"))
.dependsOn(lighthouse, `lighthouse-testing` % "test->compile")
.settings(buildSettings, publishArtifact := false, libraryDependencies ++= commonDependencies)