-
Notifications
You must be signed in to change notification settings - Fork 130
/
Copy pathbuild.sbt
77 lines (68 loc) · 2.33 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
// basics
val scala213 = "2.13.12"
val scala3 = "3.4.0"
val scala2 = Seq("2.11.12", "2.12.18", scala213)
val isScala3 = Def.setting {
CrossVersion.partialVersion(scalaVersion.value).exists(_._1 != 2)
}
import com.typesafe.sbt.osgi.SbtOsgi
import sbt.url
lazy val root = (project in file(".")).aggregate(main, scala2macros)
lazy val main = (project in file("main"))
.enablePlugins(SbtOsgi)
.settings(
name := "scala-logging",
crossScalaVersions := Seq(scala3) ++ scala2,
scalaVersion := crossScalaVersions.value.head,
ThisBuild / versionScheme := Some("early-semver"),
scalacOptions ++= Seq(
"-unchecked",
"-deprecation",
"-language:_",
"-encoding", "UTF-8",
"-Ywarn-unused"
),
incOptions := incOptions.value.withLogRecompileOnMacro(false),
libraryDependencies ++= Dependencies.scalaLogging(scalaVersion.value, isScala3.value),
initialCommands := """|import com.typesafe.scalalogging._
|import org.slf4j.{ Logger => Underlying, _ }""".stripMargin
).settings(
// OSGi
osgiSettings
).settings(
OsgiKeys.bundleSymbolicName := "com.typesafe.scala-logging",
OsgiKeys.privatePackage := Seq(),
OsgiKeys.exportPackage := Seq("com.typesafe.scalalogging*"),
// publishing
organization := "com.typesafe.scala-logging",
sonatypeProfileName := "com.typesafe",
licenses := Seq("Apache 2.0 License" -> url("http://www.apache.org/licenses/LICENSE-2.0.html")),
homepage := Some(url("https://github.com/lightbend/scala-logging")),
Test / publishArtifact := false,
pomIncludeRepository := (_ => false),
scmInfo := Some(
ScmInfo(url("https://github.com/lightbend/scala-logging"), "scm:git:[email protected]:lightbend/scala-logging.git")
),
developers := List(
Developer(
id = "hseeberger",
name = "Heiko Seeberger",
email = "",
url = url("http://heikoseeberger.de")
),
Developer(
id = "analytically",
name = "Mathias Bogaert",
email = "",
url = url("http://twitter.com/analytically")
)
)
)
.dependsOn(scala2macros)
lazy val scala2macros = project
.settings(
name := "scala2macros",
scalaVersion := scala213,
crossScalaVersions := scala2,
libraryDependencies ++= Dependencies.scalaLogging(scalaVersion.value, false),
)