forked from NikinAI/TypedGraph
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sbt
50 lines (45 loc) · 2.06 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
lazy val root =
project
.in(file("."))
.enablePlugins(GitVersioning)
. enablePlugins(BuildInfoPlugin)
.settings(
scalaVersion := "2.13.10",
name := "Typed Graph",
organization := "ai.nikin",
organizationName := "NikinAI",
libraryDependencies += "org.scalameta" %% "munit" % "0.7.29",
addCommandAlias("runScalafmt", ";scalafmtAll;scalafmtSbt"),
scalacOptions ++=
Seq(
"-Xlint:adapted-args",
// Warn if an argument list is modified to match the receiver.
"-Xlint:nullary-unit",
// Warn when nullary methods return Unit.
"-Xlint:inaccessible",
// Warn about inaccessible types in method signatures.
"-Xlint:infer-any",
// Warn when a type argument is inferred to be Any.
"-Xlint:constant",
// Evaluation of a constant arithmetic expression results in an error.
"-Ywarn-unused:imports", "-Xfatal-warnings", "-deprecation", "-Ywarn-dead-code",
"-Ywarn-unused:params", "-Ywarn-unused:locals", "-Ywarn-value-discard",
"-Ywarn-unused:privates",
),
// https://github.com/target/data-validator/blob/d3ae90ea1c84d922e50ad097f517e44852711c1c/build.sbt#LL11-L12C27
git.useGitDescribe := true,
// https://github.com/target/data-validator/blob/d3ae90ea1c84d922e50ad097f517e44852711c1c/build.sbt#LL27
publishTo := githubPublishTo.value,
// https://github.com/djspiewak/sbt-github-packages#usage
githubOwner := "NikinAI",
githubRepository := "TypedGraph",
publishMavenStyle := true,
// https://github.com/djspiewak/sbt-github-packages/issues/24#issuecomment-898423448
githubTokenSource :=
TokenSource.Or(
// Injected during a github workflow for publishing
TokenSource.Environment("GITHUB_TOKEN"),
// local token set in ~/.gitconfig
TokenSource.GitConfig("github.token"),
),
)