-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.sbt
60 lines (50 loc) · 1.84 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
name := "overflowdb2"
ThisBuild / organization := "io.appthreat"
ThisBuild / version := "1.0.1"
ThisBuild / scalaVersion := "3.5.2"
publish / skip := true
lazy val core = project.in(file("core"))
lazy val testdomains = project.in(file("testdomains")).dependsOn(core)
lazy val traversal = project.in(file("traversal")).dependsOn(core)
lazy val formats = project.in(file("formats")).dependsOn(traversal, testdomains % Test)
lazy val coreTests = project.in(file("core-tests")).dependsOn(formats, testdomains)
lazy val traversalTests = project.in(file("traversal-tests")).dependsOn(formats)
ThisBuild / libraryDependencies ++= Seq(
"org.scalatest" %% "scalatest" % "3.2.19" % Test
)
ThisBuild / scalacOptions ++= Seq(
"-release",
"21",
"-deprecation"
)
ThisBuild / compile / javacOptions ++= Seq(
"-g", // debug symbols
"-Xlint",
"--release=21"
) ++ {
// fail early if users with JDK11 try to run this
val javaVersion = sys.props("java.specification.version").toFloat
assert(javaVersion.toInt >= 21, s"this build requires JDK21+ - you're using $javaVersion")
Nil
}
ThisBuild / Test / testOptions += Tests.Argument(TestFrameworks.JUnit, "-a", "-v")
ThisBuild / Test / fork := true
ThisBuild / resolvers ++= Seq(
Resolver.mavenLocal,
Resolver.githubPackages("appthreat/overflowdb2"),
"Sonatype OSS".at("https://oss.sonatype.org/content/repositories/public")
)
ThisBuild / licenses := List("Apache-2.0" -> url("http://www.apache.org/licenses/LICENSE-2.0"))
ThisBuild / versionScheme := Some("semver-spec")
Global / cancelable := true
Global / onChangedBuildSource := ReloadOnSourceChanges
githubOwner := "appthreat"
githubRepository := "overflowdb2"
githubSuppressPublicationWarning := true
credentials +=
Credentials(
"GitHub Package Registry",
"maven.pkg.github.com",
"appthreat",
sys.env.getOrElse("GITHUB_TOKEN", "N/A")
)