From 2892241af5e3f11984ce090f0ce5c61b7abb3fd2 Mon Sep 17 00:00:00 2001 From: saeltz Date: Fri, 24 Nov 2023 21:29:40 +0100 Subject: [PATCH] Use slf4j2-impl --- build.sbt | 120 +++++++++++++++++++++++++----------------------------- 1 file changed, 56 insertions(+), 64 deletions(-) diff --git a/build.sbt b/build.sbt index c6ae766..2bb173d 100644 --- a/build.sbt +++ b/build.sbt @@ -63,31 +63,30 @@ lazy val integrationTestConfig = // Dependencies // ***************************************************************************** -lazy val library = - new { - object Version { - val akka = "2.6.20" - val akkaHttp = "10.2.10" - val log4j = "2.22.0" - val pureConfig = "0.17.4" - val scalaCheck = "1.17.0" - val scalaLogging = "3.9.5" - val scalaTest = "3.2.17" - } - val akkaActor = "com.typesafe.akka" %% "akka-actor-typed" % Version.akka - val akkaHttp = "com.typesafe.akka" %% "akka-http" % Version.akkaHttp - val akkaHttpTestkit = "com.typesafe.akka" %% "akka-http-testkit" % Version.akkaHttp - val akkaStream = "com.typesafe.akka" %% "akka-stream-typed" % Version.akka - val akkaTestkit = "com.typesafe.akka" %% "akka-actor-testkit-typed" % Version.akka - val log4jApi = "org.apache.logging.log4j" % "log4j-api" % Version.log4j - val log4jCore = "org.apache.logging.log4j" % "log4j-core" % Version.log4j - val logJulOverLog4j = "org.apache.logging.log4j" % "log4j-jul" % Version.log4j - val logSlfOverLog4j = "org.apache.logging.log4j" % "log4j-slf4j-impl" % Version.log4j - val pureConfig = "com.github.pureconfig" %% "pureconfig" % Version.pureConfig - val scalaCheck = "org.scalacheck" %% "scalacheck" % Version.scalaCheck - val scalaLogging = "com.typesafe.scala-logging" %% "scala-logging" % Version.scalaLogging - val scalaTest = "org.scalatest" %% "scalatest" % Version.scalaTest +lazy val library = new { + object Version { + val akka = "2.6.20" + val akkaHttp = "10.2.10" + val log4j = "2.22.0" + val pureConfig = "0.17.4" + val scalaCheck = "1.17.0" + val scalaLogging = "3.9.5" + val scalaTest = "3.2.17" } + val akkaActor = "com.typesafe.akka" %% "akka-actor-typed" % Version.akka + val akkaHttp = "com.typesafe.akka" %% "akka-http" % Version.akkaHttp + val akkaHttpTestkit = "com.typesafe.akka" %% "akka-http-testkit" % Version.akkaHttp + val akkaStream = "com.typesafe.akka" %% "akka-stream-typed" % Version.akka + val akkaTestkit = "com.typesafe.akka" %% "akka-actor-testkit-typed" % Version.akka + val log4jApi = "org.apache.logging.log4j" % "log4j-api" % Version.log4j + val log4jCore = "org.apache.logging.log4j" % "log4j-core" % Version.log4j + val logJulOverLog4j = "org.apache.logging.log4j" % "log4j-jul" % Version.log4j + val logSlfOverLog4j = "org.apache.logging.log4j" % "log4j-slf4j2-impl" % Version.log4j + val pureConfig = "com.github.pureconfig" %% "pureconfig" % Version.pureConfig + val scalaCheck = "org.scalacheck" %% "scalacheck" % Version.scalaCheck + val scalaLogging = "com.typesafe.scala-logging" %% "scala-logging" % Version.scalaLogging + val scalaTest = "org.scalatest" %% "scalatest" % Version.scalaTest +} // ***************************************************************************** // Settings @@ -103,49 +102,42 @@ lazy val commonSettings = sbtGitSettings ++ mimaSettings -lazy val compilerSettings = - Seq( - scalaVersion := "2.13.11", - versionScheme := Some("early-semver"), - Compile / packageBin / mappings += baseDirectory.value / "LICENSE" -> "LICENSE", - scalacOptions ++= Seq( - "-unchecked", - "-deprecation", - "-language:_", - "-release", - "8", - "-encoding", - "UTF-8", - "-DLog4jContextSelector=org.apache.logging.log4j.core.async.AsyncLoggerContextSelector", - "-Xfatal-warnings", - "-Xlint:_,-byname-implicit", - "-Ywarn-numeric-widen", - "-Ywarn-dead-code", - "-Ywarn-value-discard", - "-Xsource:3" - ), - javacOptions ++= Seq( - "-source", - "1.8", - "-target", - "1.8" - ), - Compile / unmanagedSourceDirectories := Seq((Compile / scalaSource).value), - Test / unmanagedSourceDirectories := Seq((Test / scalaSource).value) - ) +lazy val compilerSettings = Seq( + scalaVersion := "2.13.11", + versionScheme := Some("early-semver"), + Compile / packageBin / mappings += baseDirectory.value / "LICENSE" -> "LICENSE", + scalacOptions ++= Seq( + "-unchecked", + "-deprecation", + "-language:_", + "-release", + "8", + "-encoding", + "UTF-8", + "-DLog4jContextSelector=org.apache.logging.log4j.core.async.AsyncLoggerContextSelector", + "-Xfatal-warnings", + "-Xlint:_,-byname-implicit", + "-Ywarn-numeric-widen", + "-Ywarn-dead-code", + "-Ywarn-value-discard", + "-Xsource:3" + ), + javacOptions ++= Seq( + "-source", + "1.8", + "-target", + "1.8" + ), + Compile / unmanagedSourceDirectories := Seq((Compile / scalaSource).value), + Test / unmanagedSourceDirectories := Seq((Test / scalaSource).value) +) lazy val gitSettings = Seq(git.useGitDescribe := true) -lazy val licenseSettings = - Seq( - headerLicense := Some( - HeaderLicense.Custom( - """|Copyright (c) MOIA GmbH 2017 - |""".stripMargin - ) - ), - headerMappings := headerMappings.value + (HeaderFileType.conf -> HeaderCommentStyle.hashLineComment) - ) +lazy val licenseSettings = Seq( + headerLicense := Some(HeaderLicense.Custom("Copyright (c) MOIA GmbH 2017")), + headerMappings := headerMappings.value + (HeaderFileType.conf -> HeaderCommentStyle.hashLineComment) +) lazy val sonatypeSettings = { import xerial.sbt.Sonatype._