-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sbt
35 lines (30 loc) · 1.04 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
name := "scala-mutual-information"
inThisBuild(
List(
version := "0.0.2",
organization := "konradmalik",
scalaVersion := "2.12.13",
crossScalaVersions := Seq("2.11.12", "2.12.13", "2.13.5"),
fork := true,
semanticdbEnabled := true,
semanticdbVersion := scalafixSemanticdb.revision,
scalafixScalaBinaryVersion := scalaBinaryVersion.value,
scalafixDependencies += "com.github.liancheng" %% "organize-imports" % "0.5.0",
)
)
scalacOptions += {
CrossVersion.partialVersion(scalaBinaryVersion.value) match {
case Some((2, n)) if n <= 12 => "-Ywarn-unused-import"
case _ => "-Ywarn-unused:imports"
}
}
githubOwner := "konradmalik"
githubRepository := "ScalaMI"
shellPrompt := (_ => fancyPrompt(name.value))
def fancyPrompt(projectName: String): String =
s"""|
|[info] Welcome to the ${cyan(projectName)} project!
|sbt> """.stripMargin
def cyan(projectName: String): String =
scala.Console.CYAN + projectName + scala.Console.RESET
addCommandAlias("lint", "scalafixAll; scalafmtAll")