Skip to content

Commit

Permalink
scala-parser-combinators stays on 1.x for Scala 2.x
Browse files Browse the repository at this point in the history
  • Loading branch information
mkurz committed Jan 3, 2022
1 parent 6fa558b commit c918c2d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ lazy val cachecontrol = (project in file("."))
.enablePlugins(Common)
.settings(
libraryDependencies ++= Seq(
parserCombinators,
parserCombinators(scalaVersion.value),
scalaTest,
slf4j,
slf4jSimple % Test
Expand Down
9 changes: 7 additions & 2 deletions project/Dependencies.scala
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,13 @@ object Dependencies {

def scalaTest = "org.scalatest" %% "scalatest" % "3.2.10" % Test

val parserCombinators =
"org.scala-lang.modules" %% "scala-parser-combinators" % "2.1.0"
def parserCombinators(scalaVersion: String) =
"org.scala-lang.modules" %% "scala-parser-combinators" % {
CrossVersion.partialVersion(scalaVersion) match {
case Some((2, _)) => "1.1.2"
case _ => "2.1.0"
}
}

val slf4jVersion = "1.7.32"
val slf4j = "org.slf4j" % "slf4j-api" % slf4jVersion
Expand Down

0 comments on commit c918c2d

Please sign in to comment.