Skip to content

Commit e883b52

Browse files
committed
Cross-compilation build process improved for 3 Scala version - 2.12, 2.13, and 3.
1 parent b7a6733 commit e883b52

File tree

2 files changed

+19
-10
lines changed

2 files changed

+19
-10
lines changed

build.sbt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,12 @@
11
import sbt.Keys.test
22

3+
// Supported versions
4+
val scala212 = "2.12.15"
5+
val scala213 = "2.13.10"
6+
val scala3 = "3.2.2"
7+
38
ThisBuild / organization := "io.cequence"
4-
ThisBuild / scalaVersion := "2.12.15" // 2.13.10"
9+
ThisBuild / scalaVersion := scala212
510
ThisBuild / version := "0.0.1"
611
ThisBuild / isSnapshot := false
712

pinecone-client/build.sbt

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,18 @@ name := "pinecone-scala-client"
22

33
description := "Scala client for Pinecone API implemented using Play WS lib."
44

5-
val playWsVersion = "2.1.10" // "2.2.0-M2"
5+
lazy val playWsVersion = settingKey[String]("Play WS version to use")
6+
7+
playWsVersion := {
8+
scalaVersion.value match {
9+
case "2.12.15" => "2.1.10"
10+
case "2.13.10" => "2.2.0-M3"
11+
case "3.2.2" => "2.2.0-M2" // Version "2.2.0-M3" was produced by an unstable release: Scala 3.3.0-RC3
12+
case _ => "2.1.10"
13+
}
14+
}
615

716
libraryDependencies ++= Seq(
8-
"com.typesafe.play" %% "play-ahc-ws-standalone" % playWsVersion,
9-
"com.typesafe.play" %% "play-ws-standalone-json" % playWsVersion
10-
)
11-
12-
// we need this for Scala 2.13
13-
//dependencyOverrides ++= Seq(
14-
// "org.scala-lang.modules" %% "scala-java8-compat" % "1.0.2"
15-
//)
17+
"com.typesafe.play" %% "play-ahc-ws-standalone" % playWsVersion.value,
18+
"com.typesafe.play" %% "play-ws-standalone-json" % playWsVersion.value
19+
)

0 commit comments

Comments
 (0)