-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sbt
101 lines (91 loc) · 3.83 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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
/*
* Copyright 2018-2024 The Developers Team.
*
* Licensed under the Apache License, Version 2.0 (the "License")
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/** The version of this project. */
lazy val VersionStreamSync = "0.18-SNAPSHOT"
/** Definition of versions for compile-time dependencies. */
lazy val VersionCloudFiles = "0.8"
lazy val VersionDisruptor = "4.0.0"
lazy val VersionLog4j = "2.24.1"
lazy val VersionPekko = "1.1.2"
lazy val VersionPekkoHttp = "1.1.0"
lazy val VersionScala = "3.3.4"
lazy val VersionScalaXml = "2.2.0"
lazy val VersionScli = "1.1.0"
/** Definition of versions for test dependencies. */
lazy val VersionScalaTest = "3.2.19"
lazy val VersionScalaTestMockito = "3.2.19.0"
lazy val VersionWireMock = "3.9.1"
scalacOptions ++=
Seq(
"-feature",
"-deprecation",
"-unchecked",
"-Xfatal-warnings",
"-new-syntax"
)
lazy val ITest = config("integrationTest") extend Test
ITest / parallelExecution := false
lazy val akkaDependencies = Seq(
"org.apache.pekko" %% "pekko-actor" % VersionPekko,
"org.apache.pekko" %% "pekko-actor-typed" % VersionPekko,
"org.apache.pekko" %% "pekko-stream" % VersionPekko,
"org.apache.pekko" %% "pekko-http" % VersionPekkoHttp,
"org.apache.pekko" %% "pekko-http-spray-json" % VersionPekkoHttp
)
lazy val cloudFilesDependencies = Seq(
"com.github.oheger" %% "cloud-files-core" % VersionCloudFiles,
"com.github.oheger" %% "cloud-files-crypt" % VersionCloudFiles,
"com.github.oheger" %% "cloud-files-cryptalg-aes" % VersionCloudFiles,
"com.github.oheger" %% "cloud-files-localfs" % VersionCloudFiles,
"com.github.oheger" %% "cloud-files-webdav" % VersionCloudFiles,
"com.github.oheger" %% "cloud-files-onedrive" % VersionCloudFiles,
"com.github.oheger" %% "cloud-files-googledrive" % VersionCloudFiles
)
lazy val loggingDependencies = Seq(
"org.apache.logging.log4j" % "log4j-api" % VersionLog4j,
"org.apache.logging.log4j" % "log4j-core" % VersionLog4j,
"org.apache.logging.log4j" % "log4j-slf4j2-impl" % VersionLog4j,
"com.lmax" % "disruptor" % VersionDisruptor
)
lazy val testDependencies = Seq(
"org.scalatest" %% "scalatest" % VersionScalaTest % Test exclude("org.scala-lang.modules", "scala-xml_3"),
"org.scalatestplus" %% "mockito-5-12" % VersionScalaTestMockito % Test exclude("org.scala-lang.modules", "scala-xml_3"),
"org.apache.pekko" %% "pekko-testkit" % VersionPekko % Test,
"org.apache.pekko" %% "pekko-actor-testkit-typed" % VersionPekko % Test,
"org.wiremock" % "wiremock" % VersionWireMock % Test
)
lazy val StreamSync = (project in file("."))
.configs(ITest)
.settings(inConfig(ITest)(Defaults.testSettings) *)
.settings(
version := VersionStreamSync,
scalaVersion := VersionScala,
libraryDependencies ++= akkaDependencies,
libraryDependencies += ("com.github.oheger" %% "scli" % VersionScli).cross(CrossVersion.for3Use2_13),
libraryDependencies += "org.scala-lang.modules" %% "scala-xml" % VersionScalaXml,
libraryDependencies ++= cloudFilesDependencies,
libraryDependencies ++= loggingDependencies,
libraryDependencies ++= testDependencies,
resolvers += Resolver.mavenLocal,
name := "stream-sync",
assembly / mainClass := Some("com.github.sync.cli.Sync"),
assembly / assemblyMergeStrategy := {
case "module-info.class" => MergeStrategy.discard
case x =>
val oldStrategy = (ThisBuild / assemblyMergeStrategy).value
oldStrategy(x)
}
)