Skip to content

Commit

Permalink
Merge pull request #805 from mkurz/slick35_scala3
Browse files Browse the repository at this point in the history
Slick 3.5.0-RC1 + Scala 3 support
  • Loading branch information
mkurz authored Feb 21, 2024
2 parents 68ba85e + 1a4e6d1 commit 168cf30
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 9 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
uses: playframework/.github/.github/workflows/cmd.yml@v3
with:
java: 17, 11
scala: 2.13.x
scala: 2.13.x, 3.x
cmd: sbt ++$MATRIX_SCALA test

finish:
Expand Down
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ To use play-slick, you need to add the following dependencies:

```scala
libraryDependencies ++= Seq(
"org.playframework" %% "play-slick" % "6.0.0",
"org.playframework" %% "play-slick-evolutions" % "6.0.0"
"org.playframework" %% "play-slick" % "6.1.0",
"org.playframework" %% "play-slick-evolutions" % "6.1.0"
)
```

Expand All @@ -47,6 +47,8 @@ The Play Slick plugin supports several different versions of Play and Slick.

| Plugin version | Play version | Slick version | Scala version |
|----------------|--------------|---------------|----------------------|
| 6.1.x | 3.0.0 | 3.5.0+ | 2.13.x/3.3.x |
| 5.3.x | 2.9.0 | 3.5.0+ | 2.13.x/3.3.x |
| 6.0.x | 3.0.0 | 3.4.1 | 2.13.x |
| 5.2.x | 2.9.0 | 3.4.1 | 2.13.x |
| 5.1.x | 2.8.16 | 3.4.1+ | 2.12.x/2.13.x |
Expand Down
9 changes: 7 additions & 2 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ lazy val commonSettings = Seq(
compile / javacOptions ++= Seq("--release", "11"),
doc / javacOptions := Seq("-source", "11"),
scalaVersion := "2.13.12",
crossScalaVersions := Seq("2.13.12"),
crossScalaVersions := Seq("2.13.12", "3.3.1"),
scalacOptions ++= Seq("-deprecation", "-feature", "-unchecked", "-encoding", "utf8") ++
(CrossVersion.partialVersion(scalaVersion.value) match {
case Some((2, 13)) => Seq("-Xsource:3")
Expand Down Expand Up @@ -56,6 +56,7 @@ lazy val `play-slick` = (project in file("src/core"))
.settings(mimaSettings)
.settings(
mimaBinaryIssueFilters ++= Seq(
ProblemFilters.exclude[DirectMissingMethodProblem]("play.api.db.slick.HasDatabaseConfig.db"),
)
)
.settings(commonSettings)
Expand All @@ -82,7 +83,11 @@ val previousVersion: Option[String] = Some("6.0.0")
ThisBuild / mimaFailOnNoPrevious := false

def mimaSettings = Seq(
mimaPreviousArtifacts := previousVersion.map(organization.value %% moduleName.value % _).toSet,
mimaPreviousArtifacts := (if (CrossVersion.binaryScalaVersion(scalaVersion.value) == "3") {
Set.empty
} else {
previousVersion.map(organization.value %% moduleName.value % _).toSet
}),
mimaBinaryIssueFilters := Seq(
)
)
6 changes: 3 additions & 3 deletions docs/manual/working/scalaGuide/main/sql/slick/code/slick.sbt
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
// #add-library-dependencies
libraryDependencies += "org.playframework" %% "play-slick" % "6.0.0"
libraryDependencies += "org.playframework" %% "play-slick" % "6.1.0"
// #add-library-dependencies

// #add-dependency-with-evolutions
libraryDependencies ++= Seq(
"org.playframework" %% "play-slick" % "6.0.0",
"org.playframework" %% "play-slick-evolutions" % "6.0.0"
"org.playframework" %% "play-slick" % "6.1.0",
"org.playframework" %% "play-slick-evolutions" % "6.1.0"
)
// #add-dependency-with-evolutions
2 changes: 1 addition & 1 deletion project/Dependencies.scala
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ object Dependencies {
object Version {
val play = _root_.play.core.PlayVersion.current

val slick = "3.4.1"
val slick = "3.5.0-RC1"
val h2 = "2.2.224"
}

Expand Down

0 comments on commit 168cf30

Please sign in to comment.