-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.sbt
More file actions
96 lines (85 loc) · 3.03 KB
/
Copy pathbuild.sbt
File metadata and controls
96 lines (85 loc) · 3.03 KB
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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
val ScalaLTS = "3.3.7"
val ScalaNext = "3.7.4"
ThisBuild / organization := "io.github.marcinzh"
ThisBuild / version := "0.20.0"
ThisBuild / scalaVersion := ScalaLTS
ThisBuild / crossScalaVersions := Seq(ScalaLTS, ScalaNext)
ThisBuild / watchBeforeCommand := Watch.clearScreen
ThisBuild / watchTriggeredMessage := Watch.clearScreenOnTrigger
ThisBuild / watchForceTriggerOnAnyChange := true
ThisBuild / scalacOptions ++= Seq(
"-deprecation",
"-feature",
"-unchecked",
// "-Wnonunit-statement",
"-Xfatal-warnings",
// Seq(
// "java.lang",
// "scala",
// "scala.Predef",
// "scala.util.chaining",
// ).mkString("-Yimports:", ",", "")
)
ThisBuild / scalacOptions += {
if (VersionNumber(scalaVersion.value).matchesSemVer(SemanticSelector(">=3.4.0")))
"-Xkind-projector:underscores"
else
"-Ykind-projector:underscores"
}
ThisBuild / publish / skip := (scalaVersion.value != ScalaLTS)
val Deps = {
val tur_v = "0.124.0"
object deps {
val specs2_core = "org.specs2" %% "specs2-core" % "5.4.0" % "test"
val turbolift_core = "io.github.marcinzh" %% "turbolift-core" % tur_v
val turbolift_bindless = "io.github.marcinzh" %% "turbolift-bindless" % tur_v
val betterFiles = ("com.github.pathikrit" %% "better-files" % "3.9.1").cross(CrossVersion.for3Use2_13)
}
deps
}
lazy val root = project
.in(file("."))
.settings(sourcesInBase := false)
.settings(publish / skip := true)
.aggregate(core, examples)
lazy val core = project
.in(file("modules/core"))
.settings(name := "beam-core")
.settings(testSettings: _*)
.settings(libraryDependencies += Deps.turbolift_core)
lazy val examples = project
.in(file("modules/examples"))
.settings(name := "beam-examples")
.settings(publish / skip := true)
.settings(Compile / run / mainClass := Some("runner.Main"))
.settings(libraryDependencies += Deps.turbolift_bindless)
.dependsOn(core)
//-------------------------------------------------
val cls = taskKey[Unit]("cls")
cls := { print("\u001b[0m\u001b[2J\u001bc") }
lazy val testSettings = Seq(
libraryDependencies += Deps.specs2_core,
Test / parallelExecution := false,
)
ThisBuild / description := "Stream processing with algebraic effects and handlers"
ThisBuild / organizationName := "marcinzh"
ThisBuild / homepage := Some(url("https://github.com/marcinzh/beam"))
ThisBuild / scmInfo := Some(ScmInfo(url("https://github.com/marcinzh/beam"), "scm:git@github.com:marcinzh/beam.git"))
ThisBuild / licenses := List("MIT" -> url("http://www.opensource.org/licenses/MIT"))
ThisBuild / versionScheme := Some("semver-spec")
ThisBuild / pomIncludeRepository := { _ => false }
ThisBuild / publishMavenStyle := true
ThisBuild / publishTo := {
val centralSnapshots = "https://central.sonatype.com/repository/maven-snapshots/"
if (isSnapshot.value) Some("central-snapshots" at centralSnapshots)
else localStaging.value
}
ThisBuild / pomExtra := (
<developers>
<developer>
<id>marcinzh</id>
<name>Marcin Żebrowski</name>
<url>https://github.com/marcinzh</url>
</developer>
</developers>
)