-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.sbt
76 lines (62 loc) · 1.69 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
name := "scala213"
import sbt.Keys._
import sbt._
version in ThisBuild := "0.0.1"
lazy val scala212v = "2.12.8"
lazy val scala213v = "2.13.0"
lazy val supportedScalaVersions = List(scala212v, scala213v)
fork in run := true
// ThisBuild / useCoursier := true
lazy val commonSettings = Seq(
organization := "com.bunic",
// crossScalaVersions := supportedScalaVersions,
scalaVersion := scala213v,
version := "0.0.1",
resolvers ++= Seq(
DefaultMavenRepository,
Resolver.jcenterRepo,
Resolver.sbtPluginRepo("releases"),
Resolver.mavenLocal,
Resolver.sonatypeRepo("releases"),
Resolver.sonatypeRepo("snapshots")
),
scalacOptions ++= CompilerOptions.cOptions
)
def baseProject(name: String): Project =
Project(name, file(name))
.settings(commonSettings: _*)
.configs(IntegrationTest)
.settings(Defaults.itSettings)
lazy val `scala213` = (project in file("."))
.aggregate(`api`, common)
lazy val `api` = baseProject("api")
.dependsOn(common)
.settings(
libraryDependencies ++= Dependencies.api,
Compile/mainClass := Some("com.bunic.scala213.Boot")
)
lazy val common = baseProject("common")
.settings(
libraryDependencies ++= Dependencies.common
)
val runServer = inputKey[Unit]("Runs web-server1")
runServer := {
(run in Compile in `api`).evaluated
}
import sbtrelease.ReleasePlugin.autoImport.ReleaseTransformations._
releaseProcess := Seq[ReleaseStep](
checkSnapshotDependencies,
inquireVersions,
runClean,
runTest,
setReleaseVersion,
commitReleaseVersion,
tagRelease,
runAssembly,
setNextVersion,
commitNextVersion,
pushChanges
)
lazy val runAssembly: ReleaseStep = ReleaseStep(
action = releaseStepCommand("assembly")
)