-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.sbt
82 lines (80 loc) · 2.68 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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
/**
* scala2ts-core SBT build script
*/
import ReleaseTransformations._
lazy val root = project.in(file("."))
.enablePlugins(BuildInfoPlugin)
.settings(
name := "scala2ts-core",
organization := "com.github.scala2ts",
scalaVersion := "2.13.1",
crossVersion := CrossVersion.binary,
crossScalaVersions := Seq(
// TODO: "2.10.7"
"2.11.12",
"2.12.11",
scalaVersion.value
),
libraryDependencies ++= Seq(
"org.scala-lang" % "scala-compiler" % scalaVersion.value % "provided",
"org.scala-lang" % "scala-reflect" % scalaVersion.value % "provided",
"com.beachape" %% "enumeratum" % "1.5.15",
"com.lihaoyi" %% "os-lib" % (scalaBinaryVersion.value match {
case "2.11" => "0.2.9"
case "2.12" | "2.13" => "0.7.0"
}),
"com.lihaoyi" %% "upickle" % (scalaBinaryVersion.value match {
case "2.11" => "0.7.4"
case "2.12" | "2.13" => "1.1.0"
})
),
buildInfoKeys := Seq(name, version, scalaVersion, sbtVersion),
buildInfoPackage := "com.github.scala2ts",
test in assembly := {},
assemblyOption in assembly :=
(assemblyOption in assembly).value.copy(includeScala = false),
/**
* There's some classpath particularities when executing compiler plugins
* so we need to make a fatjar
* @see https://www.scala-lang.org/old/node/6664.html
* @see https://github.com/sbt/sbt/issues/2255
*/
packageBin in Compile := (assembly in Compile).value,
releaseCrossBuild := true,
releaseProcess := Seq[ReleaseStep](
checkSnapshotDependencies,
inquireVersions,
runClean,
runTest,
setReleaseVersion,
commitReleaseVersion,
tagRelease,
releaseStepCommandAndRemaining("+publishSigned"),
releaseStepCommand("sonatypeBundleRelease"),
setNextVersion,
commitNextVersion,
pushChanges
),
pomExtra :=
<url>https://www.github.com/scala2ts/scala2ts-core</url>
<licenses>
<license>
<name>MIT</name>
<distribution>repo</distribution>
</license>
</licenses>
<scm>
<url>[email protected]:scala2ts/scala2ts-core.git</url>
<connection>scm:git:[email protected]:scala2ts/scala2ts-core.git</connection>
</scm>
<developers>
<developer>
<id>halfmatthalfcat</id>
<name>Matt Oliver</name>
<url>https://www.github.com/halfmatthalfcat</url>
</developer>
</developers>,
publishMavenStyle := true,
publishTo := sonatypePublishToBundle.value,
resolvers ++= Seq(DefaultMavenRepository)
)