Repository navigation
Expand file tree
/
Copy pathbuild.sbt
More file actions
73 lines (61 loc) · 2.47 KB
/
Copy pathbuild.sbt
File metadata and controls
73 lines (61 loc) · 2.47 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
import com.typesafe.tools.mima.core._
import xerial.sbt.Sonatype._
import org.typelevel.sbt.TypelevelMimaPlugin
// Global / onChangedBuildSource := ReloadOnSourceChanges
ThisBuild / tlBaseVersion := "0.2"
ThisBuild / organization := "io.github.arainko"
ThisBuild / organizationName := "arainko"
ThisBuild / startYear := Some(2023)
ThisBuild / licenses := Seq(License.Apache2)
ThisBuild / developers := List(tlGitHubDev("arainko", "Aleksander Rainko"))
ThisBuild / tlSonatypeUseLegacyHost := false
ThisBuild / scalaVersion := "3.3.1"
ThisBuild / semanticdbEnabled := true
ThisBuild / semanticdbVersion := scalafixSemanticdb.revision
ThisBuild / mimaBinaryIssueFilters ++= Seq(
ProblemFilters.exclude[Problem]("io.github.arainko.ducktape.internal.*")
)
ThisBuild / tlCiReleaseBranches := Seq("series/0.1.x", "series/0.2.x")
ThisBuild / tlCiScalafixCheck := true
ThisBuild / tlCiScalafmtCheck := true
ThisBuild / githubWorkflowJavaVersions := Seq(JavaSpec.temurin("17"))
ThisBuild / githubWorkflowUseSbtThinClient := true
ThisBuild / githubWorkflowBuild += WorkflowStep.Run(
name = Some("Check docs"),
commands = "sbt --client docs/mdoc" :: Nil,
cond = Some(s"matrix.project == '${root.jvm.id}'")
)
ThisBuild / tlVersionIntroduced := Map("3" -> "0.1.6")
lazy val root = tlCrossRootProject.aggregate(ducktape)
lazy val ducktape =
crossProject(JVMPlatform, JSPlatform, NativePlatform)
.crossType(CrossType.Pure)
.enablePlugins(TypelevelMimaPlugin)
.in(file("ducktape"))
.settings(
scalacOptions ++= List("-deprecation", "-Wunused:all"),
Test / scalacOptions --= List("-deprecation"),
libraryDependencies += "org.scalameta" %%% "munit" % "1.0.0-M10" % Test
)
.dependsOn(tooling)
lazy val tooling =
crossProject(JVMPlatform, JSPlatform, NativePlatform)
.crossType(CrossType.Pure)
.disablePlugins(MimaPlugin)
.enablePlugins(NoPublishPlugin)
.in(file("tooling"))
lazy val docs =
project
.in(file("documentation"))
.enablePlugins(NoPublishPlugin, MdocPlugin)
.disablePlugins(MimaPlugin)
.settings(
mdocVariables := Map("VERSION" -> tlLatestVersion.value.mkString),
libraryDependencies += ("org.scalameta" %% "scalafmt-dynamic" % "3.6.1").cross(CrossVersion.for3Use2_13)
)
.dependsOn(ducktape.jvm)
lazy val generateReadme = taskKey[Unit]("gen readme")
generateReadme := Def.task {
val docOutput = (docs / mdocOut).value
IO.copyFile(docOutput / "readme.md", file("README.md"))
}.dependsOn((docs / mdoc).toTask("")).value